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

Charts still open even with open_charts: False #1453

Open
istrupin opened this issue Dec 7, 2024 · 2 comments
Open

Charts still open even with open_charts: False #1453

istrupin opened this issue Dec 7, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@istrupin
Copy link

istrupin commented Dec 7, 2024

System Info

OS Version: MacOS Sequoia
Python Version: 3.11
pandasai version: 2.3.0

🐛 Describe the bug

When I set my config to not open charts, it seems like the setting is not respected:

config = { "verbose": True, "llm": _get_llm(), "open_charts": False, "enable_cache": False, "save_charts": True, "save_logs": False, }

Looking at the verbose output, I see that plt.show() is still being called.

This seems almost identical to #1270 -- perhaps there was a regression since that was fixed.

Copy link

dosubot bot commented Dec 7, 2024

Hey @istrupin! I'm here to assist you with any bugs, questions, or contributions you have. Let's squash those bugs together! 🤖

There is a similar open issue, #1270, where the problem was that charts were shown despite setting the open_charts configuration to False. The suggested solution involved modifying the code to handle or remove the plt.show() call. A fork was created to address this issue, and you can view the specific change made in the fork here [1].

Additionally, there is a test in the codebase, test_return_value_without_display, that verifies the behavior of the open_charts configuration option. This test ensures that when open_charts is set to False, the plot is not displayed, indicating that the configuration should work as intended [2].

It might be worth checking if there have been any recent changes or regressions in the codebase that could have affected this behavior.

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other

@dosubot dosubot bot added the bug Something isn't working label Dec 7, 2024
@istrupin
Copy link
Author

istrupin commented Dec 7, 2024

I can confirm that the plot does indeed still show.

Also the PR submitted in the fork looks like it is not in the Sinaptik-AI Repo here

I'm happy to submit a similar PR if that would be helpful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant