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
Fix opening file dialogs in PySide #5492
Conversation
Codecov Report
@@ Coverage Diff @@
## main #5492 +/- ##
=======================================
Coverage 89.31% 89.32%
=======================================
Files 600 600
Lines 51060 51066 +6
=======================================
+ Hits 45605 45614 +9
+ Misses 5455 5452 -3
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
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.
I merged this with the other pyside6 PR and it works nice.
Makes sense to me.
Out of curiosity, it's >10 lines duplicated—does it make sense from a maintenance PoV to make this a function?
done |
Bah, you didn't have to! I was just asking! 😬 BTW I get this message in console:
Seems like it may be macOS 13 specific: |
but it is improvement |
Kinda amazing this was missed this long, but I have to admit when I was new I used File > Sample and drag-n-drop and now I largely use those two plus programatic methods. So I'm never doing File > Open. |
An badly it is not possible to test this in normal way. Maybe I should bring issue to provide both PySide and PyQt bundles? |
* main: (38 commits) Fix `test_worker_with_progress` by wait on worker end (napari#5548) Un-set unified title and tool bar on mac (Qt property) (napari#5533) Set PYTHONEXECUTABLE as part of macos fixes on (re)startup (napari#5531) Fix key error issue of action manager (napari#5539) Clean dangling widget in test (napari#5544) Use pytest-pretty for better log readability (napari#5525) Update vendoring tool to check on matplotlib colormap (napari#5181) MAINT: add time limit for CI. (napari#5495) Add show_debug notification (napari#5101) Overlays 2.0 (napari#4894) Clarify layer's editable property and separate interaction with visible property (napari#5413) ci(dependabot): bump docker/build-push-action from 3 to 4 (napari#5523) Fix opening file dialogs in PySide (napari#5492) [pre-commit.ci] pre-commit autoupdate (napari#5518) Replace flake8, isort and pyupgrade by ruff, enable additional usefull rules (napari#5513) MAINT: Don't format logs in log call (napari#5504) Fix conda avaliability check (napari#5496) Handle case when QtDims play thread is partially deleted (napari#5499) Bugfix: Add missing Enums and Flags required by PySide6 > 6.4 (napari#5480) Refactor Main Window status bar to improve information presentation (napari#5451) ...
Description
Even if official documentation of qt says that the argument of
getOpenFileNames
is nameddir
, thedir
is a builtin function in python, so PySide2, PyQt5, and PyQt6 usedirectory
as the argument name. But PySide6 breaks this.The
PyQt6
does not supportQFileDialog.Options()
Type of change
References
How has this been tested?
as there are small differences between the two Qt bindings.
Final checklist:
trans.
to make them localizable.For more information see our translations guide.