Pycharm: Cannot find reference ‘xxx‘ in __init__.py

stackoverflow

May be to respect this feature

The only solution is for the package author to provide an explicit index of the package. The import statement uses the following specification: If the __init__.py code of a package defines a list named __all__, it will be treated as a list of module names that should be imported when from package import * is encountered. When a new version of the package is released, the package author can decide whether to keep this list updated. Package authors can decide not to support this list if they think that the import* operation from their package is unnecessary to be used.

Guess you like

Origin blog.csdn.net/qq_16056397/article/details/111241440