Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with streamlit-condition-tree Component Not Updating Correctly with "config" #1

Open
andreabandinu opened this issue Nov 17, 2023 · 1 comment

Comments

@andreabandinu
Copy link

andreabandinu commented Nov 17, 2023


Description

I'm experiencing an issue with the streamlit-condition-tree component in my Streamlit application where the component does not seem to update correctly with its configuration. Initially, the component displays a default "index in index" query string, and then it should update based on user interaction and configuration changes. However, this update does not seem to occur as expected.
Steps to Reproduce

  • Initialize the streamlit-condition-tree component with a DataFrame configuration.
  • Run the Streamlit application.
  • Interact with the component or trigger an update.
  • Observe that the component does not update as expected and remains at the default state.

Expected Behavior

Upon interaction or receiving new configuration data, the streamlit-condition-tree component should update and reflect the changes based on user input or updated configuration.


Current Behavior

The component initializes with a default "index in index" state but does not update as expected with user interactions or when provided with new configuration data.


Environment

Streamlit version: 1.28.2
streamlit-condition-tree version: 0.1.2
Browser version: Chrome Version 119.0.6045.159 (Official Build) (64-bit) / Firefox 119.0.1 (64-bit)
Operating System: Ubuntu 22.04.3 LTS

Additional Context and Observations

The debug logs show that the component is registered and the script reruns on interaction, but the component's state does not seem to update with the new configuration.
Initial tests with different configurations suggest that the issue might be related to how the component's state is managed in Streamlit's reactive framework.
I have tried various troubleshooting steps, including checking the component's initialization, ensuring correct configuration formats, and testing in different environments (local and deployed).


I really appreciate the functionality that streamlit-condition-tree brings to Streamlit applications, and I'm eager to resolve this issue. Any insights or suggestions from the community or maintainers would be incredibly helpful.

Thank you for your time and effort in developing and maintaining this useful component.

@cedricvlt
Copy link
Owner

Hi @andreabandinu,

Sorry for my late answer and thanks for the effort to report this issue. However, I don't really manage to understand in what context this occurs. In general, as you can see in the demo, the component state and its outputs are updated when the user interacts with it.
Can you please share a minimal example of the code that generates this issue ? Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants