Skip to content

Post-mortem for broken web3 4.7.0 release. #1053

Closed
@dylanjw

Description

@dylanjw

See #1052

It was discovered that web3 4.7.0 would attempt to install pypiwin32 on all
platforms when installed from pypi with pip whereas a local install with setup.py or
the built tar.gz package did not.

Ref:

setuptools had a bug where environment markers get stripped from the wheel's
MANIFEST.

I had started out building with the broken package with pip version 9.0.3 and
setuptools 28.8.0. (doh!)

$ python setup.py sdist bdist_wheel
$ grep pypiwin32 web3.egg-info/requires.txt
pypiwin32>=223;platform_system=='Windows'

$ mkdir web3_whl; cd web3_whl
$ unzip ../dist/web3-4.7.0-py3-none-any.whl
$ grep pypiwin32 web3-4.7.0.dist-info/METADATA
Requires-Dist: pypiwin32 (>=223)

Upgrading pip was not sufficient to fix the issue:

$ pip install pip --upgrade
$ pip show pip
Name: pip
Version: 18.0
Summary: The PyPA recommended tool for installing Python packages.
Home-page: https://pip.pypa.io/
Author: The pip developers
Author-email: pypa-dev@groups.google.com
License: MIT
Location: /home/dwilson/Develop/Projects/ethereum/web3.py/venv-test/lib/python3.6/site-packages
Requires: 
Required-by: 
$ pip show setuptools
Name: setuptools
Version: 28.8.0
Summary: Easily download, build, install, upgrade, and uninstall Python packages
Home-page: https://github.com/pypa/setuptools
Author: Python Packaging Authority
Author-email: distutils-sig@python.org
License: UNKNOWN
Location: /home/dwilson/Develop/Projects/ethereum/web3.py/venv-test/lib/python3.6/site-packages
Requires: 
Required-by: 

$ python setup.py sdist bdist_wheel
$ grep pypiwin32 web3.egg-info/requires.txt
pypiwin32>=223;platform_system=='Windows'
$ grep pypiwin32 web3-4.7.0.dist-info/METADATA
Requires-Dist: pypiwin32 (>=223)

After upgrading setuptools the MANIFEST file included in the wheel contains the
environment markers.

$ pip install setuptools --upgrade
Collecting setuptools
  Using cached https://files.pythonhosted.org/packages/66/e8/570bb5ca88a8bcd2a1db9c6246bb66615750663ffaaeada95b04ffe74e12/setuptools-40.2.0-py2.py3-none-any.whl
Installing collected packages: setuptools
  Found existing installation: setuptools 28.8.0
    Uninstalling setuptools-28.8.0:
      Successfully uninstalled setuptools-28.8.0
Successfully installed setuptools-40.2.0
$ grep pypiwin32 web3-4.7.0.dist-info/METADATA
Requires-Dist: pypiwin32 (>=223); platform_system == "Windows"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions