Skip to content
This repository has been archived by the owner on Jan 29, 2024. It is now read-only.

Add zip_safe=False to setup.py #197

Merged
merged 1 commit into from
Dec 21, 2020
Merged

Add zip_safe=False to setup.py #197

merged 1 commit into from
Dec 21, 2020

Conversation

Stannislav
Copy link
Contributor

According to
https://mypy.readthedocs.io/en/latest/installed_packages.html#installed-packages

"If you use setuptools, you must pass the option zip_safe=False to setup(),
or mypy will not be able to find the installed package."

According to
https://mypy.readthedocs.io/en/latest/installed_packages.html#installed-packages

"If you use setuptools, you must pass the option zip_safe=False to setup(),
or mypy will not be able to find the installed package."
@Stannislav
Copy link
Contributor Author

@FrancescoCasalegno sorry I'm late for reviewing #192 I just scrolled through the changes and then stumbled upon the note about zip_safe in the mypy documentation. What do you think?

Copy link
Contributor

@FrancescoCasalegno FrancescoCasalegno left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Feel free to merge with master!

I am actually surprised to learn that mypy should not have been able to find our package, as in my environment it seemed to work fine.

@Stannislav
Copy link
Contributor Author

Here are more details about why it's recommended to have zip_safe=False: python/mypy#8802

If I understand correctly, it's important only if one uses the (legacy) python setup.py install syntax instead of pip install ..

@FrancescoCasalegno FrancescoCasalegno merged commit 8bbb2ec into master Dec 21, 2020
@FrancescoCasalegno FrancescoCasalegno deleted the zip_safe branch December 21, 2020 08:07
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants