Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
Return filename from save_figure#27766
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Thank you for opening your first PR into Matplotlib!
If you have not heard from us in a week or so, please leave a new comment below and that should bring it to our attention. Most of our reviewers are volunteers and sometimes things fall through the cracks.
You can also join uson gitter for real-time discussion.
For details on testing, writing docs, and our review process, please seethe developer guide
We strive to be a welcoming and open project. Please follow ourCode of Conduct.
62fe3f4
to1ec4655
CompareWe can probably use a closure / I agree we the webagg one looks like a big lift because I don't think we currently have a response back over the websocket. Even if we added that, it is not super clear it would be useful as the filesystems that the client (in a browser possibly on a different machine) is in general not the filesystem that the server sees. There is also a good case we shouldnot leak anything about the client file system back to the server. |
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
If we want to differentiate between "I did not save a file" and "I can not tell you if a file was saved" we could return a different sentinel in the "I did not save a file case". The simplest thing (from an implement ion point of view...typing this proposal would be hard) would be to add |
That is a good idea. I'll do that. |
Zybulon commentedFeb 10, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Usually the FileDialogs (from Qt, Gtk etc...) return |
f8a3028
toc474811
Compare64b6642
to20c4e55
CompareHello, |
"power-cycled" to re-trigger CI. |
QuLogic commentedOct 12, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Unfortunately, this is failing on the newly-added test. |
The failure is gtk setting itself up on python313:
|
ff262a1
intomatplotlib:mainUh oh!
There was an error while loading.Please reload this page.
Thanks@Zybulon and congratulations on your first contribution to Matplotlib. 🎉 We hope to hear from you again! |
The failing tests were not fixed yet... |
timhoffm commentedOct 29, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
which one? I thought the gtk3 python313 issue mentioned above is unrelated - Ok, my understanding: While it is unrelated, the intoduced test exercises a new gtk3 code path, which is broken. |
Uh oh!
There was an error while loading.Please reload this page.
Closes#27744
PR summary
This PR adresses issue#27744.
save_figure functions from the NavigationToolbar return the filename of the saved figure.
If no figure is save then it returns None.
For GTK4 backend and Web backend I could not get the filename so the function still returns None.
PR checklist