-
Notifications
You must be signed in to change notification settings - Fork 3
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
slight tidy #129
slight tidy #129
Conversation
for more information, see https://pre-commit.ci
@@ -488,10 +471,10 @@ def __init__(self, parent=None): | |||
|
|||
|
|||
class FormDockWidget(QtWidgets.QDockWidget): | |||
def __init__(self, parent=None, title=None): | |||
def __init__(self, parent=None, title=''): |
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.
why this default and accept title=None
?
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.
honestly I'd prefer removing the lines below:
if title is None:
title = ''
but I left them in just for backwards compatibility.
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.
honestly I'd prefer removing the lines below:
if title is None: title = ''but I left them in just for backwards compatibility.
we added these lines in https://github.com/TomographicImaging/eqt/pull/102/files
to fix some problems. the default title = None was already set then.
CHANGELOG.md
Outdated
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.
The new changes are not passing the tests, could you fix this before we look at it? (101 fail, 36 pass on my local machine)
name_role = name + '_' + role | ||
else: | ||
raise ValueError(f'Role must be either "label", "field" or None. Got {role}.') | ||
else: | ||
name_role = f'{name}_field' | ||
|
||
# retrieve widget | ||
try: |
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.
Why are we removing this KeyError?
I fixed the problems and approved the changes. |
after #109 :)