mkinit
mkinit copied to clipboard
Import from pyi files
I have .pyi file with typings and mkinit ignores it and does not import
from .songbird import (
...
)
# <AUTOGEN_INIT>
pass
# </AUTOGEN_INIT>
And if you do so, then it does not add the imports from .songbird(songbird.pyi) to __all__
I don't think anything except type-checkers themselves support pyi files. IIUC, types from pyi files don't even get added as __annotations__.
I would need a more detailed example of what information a pyi file could have than the corresponding py file that mkinit could use, because as the moment I don't quite understand, all of the function names should be introspectable from py files alone, unless I'm missing something.