[issue37685] Fix equality checks for some types

Serhiy Storchaka report at bugs.python.org
Thu Jul 25 17:07:46 EDT 2019


New submission from Serhiy Storchaka <storchaka+cpython at gmail.com>:

The __eq__ implementation should return NotImplemented instead of False or raising an exception (like AttributeError or TypeError) when it does not support comparison with the other operand's type. It is so for most of implementations in the stdlib, but there are several exceptions. The proposed patch fixes these cases.

----------
components: Library (Lib)
messages: 348452
nosy: serhiy.storchaka
priority: normal
severity: normal
status: open
title: Fix equality checks for some types
type: behavior
versions: Python 3.7, Python 3.8, Python 3.9

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue37685>
_______________________________________


More information about the Python-bugs-list mailing list