Hello Sphinx community,
I have gotten a TypeError when I build sphinx with autodoc.
"*Union*" type hint replaced operator "*|*" in Python 3.10. And, I add into
autodoc_mock_imports for *dbus* package which has external dependencies.
So, in my case, there is an method`s arguments:
*foo_arg: dbus.UInt16 | dbus.Array*
The Sphinx make TypeError when I build sphinx with autodoc:
*TypeError: unsupported operand type(s) for |: 'UInt16' and 'Array'*
How can I resolve this problem?
*My environment:*
Python: 3.10.6
Sphinx: 5.0.2 (but there is still problem when I upgraded 6.1.3)
conf.py:
extensions = ["sphinx.ext.autodoc"]
autodoc_mock_imports = ["gi", "dbus"]
Let me know what you think or if anything is missing.
Regards,
Junho
--
You received this message because you are subscribed to the Google Groups
"sphinx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/sphinx-users/96a8c9c5-6a1a-442c-8a5f-0a3bb9012f21n%40googlegroups.com.