-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Labels
documentationImprovements or additions to documentationImprovements or additions to documentationgood first issueGood for newcomersGood for newcomers
Description
Fedora report: https://bugzilla.redhat.com/show_bug.cgi?id=1808601
When the dependencies are defined as:
[testenv]
deps = -rrequirements.txt
We need to read the files (recursively) and output their content.
The code that handles this now is
tox-current-env/src/tox_current_env/hooks.py
Lines 161 to 172 in dc47ce3
| @tox.hookimpl | |
| def tox_runtest(venv, redirect): | |
| """If --print-deps-only, prints deps instead of running tests""" | |
| config = venv.envconfig.config | |
| unsupported_raise(config, venv) | |
| if config.option.print_deps_path is not None: | |
| with open(config.option.print_deps_path, "a", encoding="utf-8") as f: | |
| print(*venv.get_resolved_dependencies(), sep="\n", file=f) | |
| return True | |
| if config.option.print_deps_only: | |
| print(*venv.get_resolved_dependencies(), sep="\n") | |
| return True |
The *venv.get_resolved_dependencies() call needs to be replaced with a custom function call. That function needs to call venv.get_resolved_dependencies() and handle "packages" that start with -r/-c specially.
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentationgood first issueGood for newcomersGood for newcomers