nutritious-hair-72580
06/18/2023, 5:21 PMValueError: Invalid requirement '//3rdparty/python:pytest': Parse error at "'//3rdpar'": Expected W:(0-9A-Za-z)
running test
with coverage ./pants test --test-use-coverage src/python/pants/backend/docker/:
in the pants repo. If I comment out this line, it works 😕broad-processor-92400
06/19/2023, 1:18 AMhappy-kitchen-89482
06/19/2023, 7:45 AMhappy-kitchen-89482
06/19/2023, 7:47 AM//
prefix should take care of thathappy-kitchen-89482
06/19/2023, 7:47 AMnutritious-hair-72580
06/19/2023, 8:21 AM~/.cache/pants
just now, but it still occurs
./pants test --test-use-coverage src/python/pants/backend/docker/:
There is no pantsd metadata at /Users/rhys.madigan/repos/pants/.pids/d54692e05ced/pantsd.
18:17:49.39 [INFO] waiting for pantsd to start...
18:17:49.60 [INFO] pantsd started
18:17:56.46 [INFO] Initializing scheduler...
18:18:07.55 [INFO] Scheduler initialized.
18:18:18.58 [ERROR] 1 Exception encountered:
Engine traceback:
in select
..
in pants.core.goals.test.run_tests
`test` goal
Traceback (most recent call last):
File "/Users/rhys.madigan/.cache/pants/pants_dev_deps/5709c1a054ca5899853199a432062f92bb7571eb.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/requirements.py", line 102, in __init__
req = REQUIREMENT.parseString(requirement_string)
File "/Users/rhys.madigan/.cache/pants/pants_dev_deps/5709c1a054ca5899853199a432062f92bb7571eb.venv/lib/python3.9/site-packages/pkg_resources/_vendor/pyparsing/core.py", line 1141, in parse_string
raise exc.with_traceback(None)
pkg_resources._vendor.pyparsing.exceptions.ParseException: Expected W:(0-9A-Za-z), found '/' (at char 0), (line:1, col:1)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/rhys.madigan/repos/pants/src/python/pants/backend/python/pip_requirement.py", line 21, in parse
return cls(pkg_resources.Requirement.parse(line))
File "/Users/rhys.madigan/.cache/pants/pants_dev_deps/5709c1a054ca5899853199a432062f92bb7571eb.venv/lib/python3.9/site-packages/pkg_resources/__init__.py", line 3147, in parse
req, = parse_requirements(s)
File "/Users/rhys.madigan/.cache/pants/pants_dev_deps/5709c1a054ca5899853199a432062f92bb7571eb.venv/lib/python3.9/site-packages/pkg_resources/__init__.py", line 3102, in __init__
super(Requirement, self).__init__(requirement_string)
File "/Users/rhys.madigan/.cache/pants/pants_dev_deps/5709c1a054ca5899853199a432062f92bb7571eb.venv/lib/python3.9/site-packages/pkg_resources/_vendor/packaging/requirements.py", line 104, in __init__
raise InvalidRequirement(
pkg_resources.extern.packaging.requirements.InvalidRequirement: Parse error at "'//3rdpar'": Expected W:(0-9A-Za-z)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/rhys.madigan/repos/pants/src/python/pants/engine/internals/selectors.py", line 626, in native_engine_generator_send
res = rule.send(arg) if err is None else rule.throw(throw or err)
File "/Users/rhys.madigan/repos/pants/src/python/pants/core/goals/test.py", line 889, in run_tests
results = await MultiGet(
File "/Users/rhys.madigan/repos/pants/src/python/pants/engine/internals/selectors.py", line 361, in MultiGet
return await _MultiGet(tuple(__arg0))
File "/Users/rhys.madigan/repos/pants/src/python/pants/engine/internals/selectors.py", line 168, in __await__
result = yield self.gets
File "/Users/rhys.madigan/repos/pants/src/python/pants/engine/internals/selectors.py", line 626, in native_engine_generator_send
res = rule.send(arg) if err is None else rule.throw(throw or err)
File "/Users/rhys.madigan/repos/pants/src/python/pants/backend/python/goals/pytest_runner.py", line 503, in run_python_tests
setup = await Get(
File "/Users/rhys.madigan/repos/pants/src/python/pants/engine/internals/selectors.py", line 118, in __await__
result = yield self
File "/Users/rhys.madigan/repos/pants/src/python/pants/engine/internals/selectors.py", line 626, in native_engine_generator_send
res = rule.send(arg) if err is None else rule.throw(throw or err)
File "/Users/rhys.madigan/repos/pants/src/python/pants/backend/python/goals/pytest_runner.py", line 373, in setup_pytest_for_target
await validate_pytest_cov_included(pytest)
File "/Users/rhys.madigan/repos/pants/src/python/pants/backend/python/goals/pytest_runner.py", line 220, in validate_pytest_cov_included
requirements = {PipRequirement.parse(req) for req in _pytest.requirements}
File "/Users/rhys.madigan/repos/pants/src/python/pants/backend/python/goals/pytest_runner.py", line 220, in <setcomp>
requirements = {PipRequirement.parse(req) for req in _pytest.requirements}
File "/Users/rhys.madigan/repos/pants/src/python/pants/backend/python/pip_requirement.py", line 49, in parse
raise ValueError(f"Invalid requirement '{line}'{origin_str}: {e}")
ValueError: Invalid requirement '//3rdparty/python:pytest': Parse error at "'//3rdpar'": Expected W:(0-9A-Za-z)
happy-kitchen-89482
06/19/2023, 8:37 AMhappy-kitchen-89482
06/19/2023, 8:43 AMhappy-kitchen-89482
06/19/2023, 8:43 AMhappy-kitchen-89482
06/19/2023, 8:43 AMhappy-kitchen-89482
06/19/2023, 8:46 AMnutritious-hair-72580
06/19/2023, 8:53 AMhappy-kitchen-89482
06/19/2023, 4:59 PM