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

Work around PyQt5 bug with argument types #3776

Merged
merged 1 commit into from
Oct 19, 2020

Conversation

ferdnyc
Copy link
Contributor

@ferdnyc ferdnyc commented Oct 19, 2020

Qt's getOpenFileUrls() and related Url-based functions are supposed to take a QUrl for the 'directory' argument (starting path), but until PyQt5 5.13.1 the argument was mis-typed as str.

This PR creates a distutils.version.LooseVersion() instance for the PYQT_VERSION_STR and stores it as self.pyqt_version in OpenShotApp.__init__.

get_app().pyqt_version is later compared to '5.13.1' when deciding how to call getOpenFileUrls() from actionImportFiles_trigger().

Fixes #3774 (4realz)

Qt's getOpenFileUrls() and related Url-based functions are supposed to
take a QUrl for the 'directory' argument (starting path), but until
PyQt5 5.13.1 the argument was mis-typed as str.
@ferdnyc ferdnyc merged commit 3d68cad into OpenShot:develop Oct 19, 2020
@ferdnyc ferdnyc deleted the qurl-file-fix branch October 19, 2020 13:45
ferdnyc added a commit that referenced this pull request Oct 19, 2020
Qt's getOpenFileUrls() and related Url-based functions are supposed to
take a QUrl for the 'directory' argument (starting path), but until
PyQt5 5.13.1 the argument was mis-typed as str.

Fix workaround
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

Successfully merging this pull request may close these issues.

Import Files dialog not working in latest Daily Build
1 participant