Skip to content

setup.py test not installing elements from extra_requires with markers #1093

@alex

Description

@alex

Steps to reproduce (requires using Python2):

$ git clone https://github.com/alex/cryptography
$ cd cryptography
$ git checkout other-style-environment-markers
$ virtualenv .venv
$ source .venv/bin/activate
$ python setup.py test
[...]
Traceback (most recent call last):
  File "setup.py", line 307, in <module>
    **keywords_with_side_effects(sys.argv)
  File "/Users/alex_gaynor/.pyenv/versions/2.7.13/lib/python2.7/distutils/core.py", line 151, in setup
    dist.run_commands()
  File "/Users/alex_gaynor/.pyenv/versions/2.7.13/lib/python2.7/distutils/dist.py", line 953, in run_commands
    self.run_command(cmd)
  File "/Users/alex_gaynor/.pyenv/versions/2.7.13/lib/python2.7/distutils/dist.py", line 972, in run_command
    cmd_obj.run()
  File "/Users/alex_gaynor/.virtualenvs/tempenv-465426949608b/lib/python2.7/site-packages/setuptools/command/test.py", line 210, in run
    with self.project_on_sys_path():
  File "/Users/alex_gaynor/.pyenv/versions/2.7.13/lib/python2.7/contextlib.py", line 17, in __enter__
    return self.gen.next()
  File "/Users/alex_gaynor/.virtualenvs/tempenv-465426949608b/lib/python2.7/site-packages/setuptools/command/test.py", line 153, in project_on_sys_path
    require('%s==%s' % (ei_cmd.egg_name, ei_cmd.egg_version))
  File "/Users/alex_gaynor/.virtualenvs/tempenv-465426949608b/lib/python2.7/site-packages/pkg_resources/__init__.py", line 971, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/Users/alex_gaynor/.virtualenvs/tempenv-465426949608b/lib/python2.7/site-packages/pkg_resources/__init__.py", line 857, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'ipaddress' distribution was not found and is required by cryptography

You can see the patch that triggers this here: pyca/cryptography#3796

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions