Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

--force-dep breaks when there are deps that include URLs in tox 2.1.1 #281

Closed
pytoxbot opened this issue Sep 17, 2016 · 2 comments
Closed

Comments

@pytoxbot
Copy link

See this travis build: https://travis-ci.org/rackerlabs/mimic/jobs/88486237

+tox --recreate --notest --force-dep 'cryptography<1.0'
Traceback (most recent call last):
  File "app_main.py", line 75, in run_toplevel
  File "/home/travis/.venv/bin/tox", line 11, in <module>
    sys.exit(cmdline())
  File "/home/travis/.venv/site-packages/tox/session.py", line 38, in main
    config = prepare(args)
  File "/home/travis/.venv/site-packages/tox/session.py", line 26, in prepare
    config = parseconfig(args)
  File "/home/travis/.venv/site-packages/tox/config.py", line 219, in parseconfig
    parseini(config, inipath)
  File "/home/travis/.venv/site-packages/tox/config.py", line 669, in __init__
    self.make_envconfig(name, section, reader._subs, config)
  File "/home/travis/.venv/site-packages/tox/config.py", line 706, in make_envconfig
    res = env_attr.postprocess(testenv_config=vc, value=res)
  File "/home/travis/.venv/site-packages/tox/config.py", line 117, in postprocess
    name = self._replace_forced_dep(name, config)
  File "/home/travis/.venv/site-packages/tox/config.py", line 133, in _replace_forced_dep
    if self._is_same_dep(forced_dep, name):
  File "/home/travis/.venv/site-packages/tox/config.py", line 144, in _is_same_dep
    dep2_name = pkg_resources.Requirement.parse(dep2).project_name
  File "/home/travis/.venv/site-packages/pkg_resources/__init__.py", line 2986, in parse
    reqs = list(parse_requirements(s))
  File "/home/travis/.venv/site-packages/pkg_resources/__init__.py", line 2930, in parse_requirements
    "version spec")
  File "/home/travis/.venv/site-packages/pkg_resources/__init__.py", line 2895, in scan_list
    raise RequirementParseError(msg, line, "at", line[p:])
RequirementParseError: Expected version spec in https://github.com/twisted/twisted/tarball/trunk at ://github.com/twisted/twisted/tarball/trunk

The offending lines in the tox.ini are:

[testenv:py34]
deps =
    "https://github.com/twisted/twisted/tarball/trunk#egg=twisted"
    "https://github.com/twisted/treq/tarball/master#egg=treq"
    "https://github.com/twisted/klein/tarball/master#egg=klein"
    {[testenv]deps}

py34 isn't even the environment being built.

@pytoxbot
Copy link
Author

Original comment by @glyph

Wow, what a turnaround! thanks! :-D

@pytoxbot
Copy link
Author

Original comment by @hpk42

fix issue281: make --force-deps work when urls are present in a dep config

→ <>

@tox-dev tox-dev locked and limited conversation to collaborators Jan 14, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant