If I create class derived from Py::PythonExtension<...> and use it from Python the functional works fine.
But if I try to use function dir(my_class) and it returns "[]". Thats why intellisense for classes doesn't work (i tried VS, PyCharm, IDLE IDEs).
I think that should be some additional private functional in generated class for intellisense support.
If i use Py::ExtensionModule<...> dir() works fine.
In python2 this was easy to support you just defined the
__dir__
property.But that was removed in python3 and there is no direct replacement.
What makes this work for python3 is using an API to create classes that I could not see how
to use in PyCXX. (I don't have the API details to hand at the moment).
Curiously this has been this way with PyCXX since I added python 3.9 support and your maybe the 2nd person to notice.
I would love to fix this, but have not figured out how.