You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Test that Hatch environments are discovered and activated #23088
using your system package manager on Arch Linux or Fedora
using pipx install Hatch on other Linux distributions. Please make sure you set your PATH correctly in this case.
Setting PATH on Linux
If you cannot install Hatch system-wide, you might need to add $HOME/.local/bin to your PATH environment variable for your graphical session, not just your terminal. Check like this:
$ pgrep bin/code # or some other graphical application1234
$ cat /proc/1234/environ | tr '\0''\n'| grep -E '^PATH='PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
If the the directory is not in there, you need to add it in your session startup script, in a way that depends on your desktop environment:
Make Hatch install the project and its dependencies to an environment using hatch run ..., e.g. hatch run python -V (there is no configuration necessary for Hatch to work in a simple case like this)
Select the testproj as an interpreter using Python: Select Interpreter command
Run it using the play icon on top right
The file is successfully run and prints the session info:
Open a new terminal: If you have the python.terminal.activateEnvironment setting set to true, the environment should be activated:
Run pip -V and compare if the path starts with the path displayed by hatch env find (pip’s contains an additional lib/pythonX.YZ/site-packages/pip)
changed the title [-][testplan-item] Test that Hatch environments are discovered and activated[/-][+]Test that Hatch environments are discovered and activated[/+]on Mar 18, 2024
Ofek Lev (@ofek) is the maintainer of both Hatch and PyApp (the framework to create the Hatch installer), and AFAIK also using Windows, so he’d need to sign it.
I personally don’t have access to any Windows machine and am therefore blissfully unaware of all the hoops Microsoft makes poor developers jump through to distribute their applications in a way that doesn’t scare users off 😄
The installers are currently created with PyOxidizer but I only have a certificate from the PSF for macOS. I'll ask about Windows today, it hasn't been a high priority.
Activity
[-][testplan-item] Test that Hatch environments are discovered and activated[/-][+]Test that Hatch environments are discovered and activated[/+]karthiknadig commentedon Mar 25, 2024
Ofek Lev (@ofek) Philipp A. (@flying-sheep) You might need to report the MSI as safe:

Another issue is that the publisher on the MSI is unknown, it is getting blocked by defender. You might need a code signing certificate for this.
flying-sheep commentedon Mar 26, 2024
Ofek Lev (@ofek) is the maintainer of both Hatch and PyApp (the framework to create the Hatch installer), and AFAIK also using Windows, so he’d need to sign it.
I personally don’t have access to any Windows machine and am therefore blissfully unaware of all the hoops Microsoft makes poor developers jump through to distribute their applications in a way that doesn’t scare users off 😄
ofek commentedon Mar 26, 2024
The installers are currently created with PyOxidizer but I only have a certificate from the PSF for macOS. I'll ask about Windows today, it hasn't been a high priority.