Skip to content

Improve error message if qt binding could not be found#205

Merged
larsoner merged 7 commits intomne-tools:mainfrom
timonmerk:patch-2
Oct 2, 2023
Merged

Improve error message if qt binding could not be found#205
larsoner merged 7 commits intomne-tools:mainfrom
timonmerk:patch-2

Conversation

@timonmerk
Copy link
Contributor

Related to #199, this PR checks before the first qtpy import if the QtBindingsNotFoundError exception is thrown. The error message now hints that pyqt5 needs to be installed.

Comment on lines 26 to 35
from qtpy.QtCore import (
QEvent,
QThread,
Qt,
Signal,
QRectF,
QLineF,
QPointF,
QPoint,
QSettings,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would also just nest one of these imports, then the rest can be as they were before. It'll make the diff smaller as well

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the comments @larsoner

timonmerk and others added 5 commits October 2, 2023 19:59
Co-authored-by: Eric Larson <larson.eric.d@gmail.com>
Co-authored-by: Eric Larson <larson.eric.d@gmail.com>
Copy link
Member

@larsoner larsoner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Marking for merge when green, thanks in advance @timonmerk !

@larsoner larsoner enabled auto-merge (squash) October 2, 2023 18:57
@larsoner larsoner merged commit 573910d into mne-tools:main Oct 2, 2023
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.

2 participants