I stumbled upon this (it is, obviously, an extract from a bigger application):
import sys
from PySide2.QtCore import *
from PySide2.QtGui import *
from PySide2.QtWidgets import *
if __name__ == '__main__':
app = QApplication(sys.argv)
d = {}
widget = QWidget()
d[widget] = 'hashable'
item = QListWidgetItem('abc')
d[item] = 'unhashable'
If you run this, on the last line you get:
TypeError: unhashable type: 'PySide2.QtWidgets.QListWidgetItem'
As far as I can tell any Qt object can be used as dict keys, just like any user-defined class instances.
I'm running PySide2 5.13.0, Python 3.6.4 on Windows 7. I get the same error on Ubuntu 18.04, Python 3.6.9, PySide 5.9.0a1.
Thanks for any hint.