Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Lib/dataclasses.py
Original file line number Diff line number Diff line change
Expand Up @@ -527,7 +527,7 @@ def add_fns_to_class(self, cls):
if already_exists and (msg_extra := self.overwrite_errors.get(name)):
error_msg = (f'Cannot overwrite attribute {fn.__name__} '
f'in class {cls.__name__}')
if not msg_extra is True:
if msg_extra is not True:
error_msg = f'{error_msg} {msg_extra}'

raise TypeError(error_msg)
Expand Down
2 changes: 1 addition & 1 deletion Lib/wsgiref/validate.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ def start_response_wrapper(*args, **kw):
environ['wsgi.errors'] = ErrorWrapper(environ['wsgi.errors'])

iterator = application(environ, start_response_wrapper)
assert_(iterator is not None and iterator != False,
assert_(iterator is not None and iterator is not False,
"The application must return an iterator, if only an empty list")

check_iterator(iterator)
Expand Down
Loading