Error/crash/hang when comparing enum value to uncomparable type

Phil Thompson phil at
Mon Oct 24 02:16:32 BST 2022

On 24/10/2022 01:45, Jean Abou Samra wrote:
> Le 24/10/2022 à 02:37, Phil Thompson a écrit :
>> No. A Python exception has been raised in a Python re-implementation 
>> of a C++ virtual. See...
> OK, thanks, that explains the failure mode, but why is there an error
> in the first place?

PyQt5 enums don't support comparisons with strings. You could argue that 
it should return False for any unsupported type (as PyQt6 does) but it's 
far too late in the lifespan of PyQt5 to change the behaviour.


More information about the PyQt mailing list