question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Means for Running `hatch test` inside of virtualenv

See original GitHub issue

Currently, the only way to really run hatch test in the project’s virtualenv is by running hatch shell . pip install hatch followed by hatch shell . hatch test. This is a little awkward to use. It would be nice if there was some sort of -env flag for hatch test that could cause it to run inside of a virtualenv. Presumably it would need to install hatch (or just the tests_require dependencies) inside of the virtualenv to facilitate this, but that seems reasonable enough.

(The intuition here being that, since hatch install automatically manages the virtualenv, it would stand to reason that hatch test should too)

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
peblaircommented, Sep 26, 2017

@ofek Sorry I didn’t get to this last night, but yes, this seems to solve it. Thanks again!

1reaction
peblaircommented, Sep 25, 2017

Awesome! I’ll plan on giving it a shot later this evening and let you know. Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Determine if Python is running inside virtualenv - Stack Overflow
The most reliable way to check for this is to check whether sys.prefix == sys.base_prefix . If they are equal, you are not...
Read more >
Python Tools for Managing Virtual Environments
What do you mean by project management? Do you mean building the package, linting, running tests, etc, as opposed to managing the environment?...
Read more >
Is hatchling really needed? · Issue #120 · pypa/hatch - GitHub
Unfortunately, that means the hatch functionality being tested really does fail at runtime in my experimental RPM package, not just in the RPM ......
Read more >
Venv Envy (A Guide to Python Virtual Environments) - Medium
zshrc stands for “run commands”.) That's why PATH is defined in your shell profile. Pyenv is the switchboard operator for your operating system....
Read more >
12. Virtual Environments and Packages — Python 3.11.1 ...
This will create the tutorial-env directory if it doesn't exist, and also create directories inside it containing a copy of the Python interpreter...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found