avoid calling PyType_GetSlot
on static types before Python 3.10
#11435
Loading
PyType_GetSlot
on static types before Python 3.10
#11435