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

test command won't have dependencies on sys.path in subprocess #794

Closed
jaraco opened this issue Sep 17, 2016 · 1 comment
Closed

test command won't have dependencies on sys.path in subprocess #794

jaraco opened this issue Sep 17, 2016 · 1 comment

Comments

@jaraco
Copy link
Member

jaraco commented Sep 17, 2016

When running the test command, or any other command that invokes with_project_on_sys_path, setuptools ensures those projects are on sys.path, but if a subprocess is launched that relies on those dependencies such as tox does or any other project that launches subprocesses to create fixtures or launch services, that subprocess won't have the projects on sys.path so will fail, as reported in tox-dev/tox#360.

On project I maintain works around this issue by adding all of sys.path to PYTHONPATH for the subprocesses. Setuptools should do something similar (though more elegant by matching only those projects added), enabling this use case in general.

@jaraco
Copy link
Member Author

jaraco commented Sep 17, 2016

It's not just the stage where with_project_on_sys_path is called, but also fetch_build_eggs.

@jaraco jaraco closed this as completed in 5e4eea7 Sep 17, 2016
jsonn pushed a commit to jsonn/pkgsrc that referenced this issue Jan 22, 2017
2.10.1
~~~~~~

* #21: Avoid mutating dictionary keys during iteration.

2.10
~~~~

* #20: Leverage technique in `setuptools 794
  <https://github.com/pypa/setuptools/issues/794>`_
  to populate PYTHONPATH during test runs such that
  Python subprocesses will have a dependency context
  comparable to the test runner.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant