-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Description
In pypa/twine#618, I'm adding py.typed
so that Twine's type annotations are recognized when it's used as an installed package. I've set zip_safe=False
as suggested by the mypy docs:
If you use setuptools, you must pass the option
zip_safe=False
tosetup()
, or mypy will not be able to find the installed package.
However, one of the other maintainers has requested removing this: pypa/twine#618 (comment)
The only references I've found to zip_safe
in the mypy repo are:
- mypy cannot find module installed as editable by pip · Issue #7508
- Support egg installs with PEP 561 searching · Issue #5007
I've done some cursory testing without setting zip_safe
, including using pip install -e path/to/twine
, and it doesn't seem to be necessary. However, the note quoted above seems unequivocal. Is it still accurate? Could it be expanded?
Caveat: I've only skimmed the issues above, and am far from an expert on the various use cases of setuptools, esp. editable installs.