-
-
Notifications
You must be signed in to change notification settings - Fork 350
Description
Hi, I have a strange behavior with how environments are managed in one of my projects.
In my pyproject.toml configuration I have, as dependencies for my module, a couple of modules set like
"module_1 @ {root:uri}/subprojects/module-1",
"module_2 @ {root:uri}/subprojects/module-2",
Which are clone as git submodules in the main module repository. Now, those modules are in turn projects managed by hatch and didn't initially include a py.typed project. However, after I added it (as well as the configuration necessary to always install it alongside the module sources for module_1 and module_2 I'm still not getting the py.typed file installed in the module directory. I can check it for example by doing
ls $(dirname $(hatch run python -c "import importlib.util, module_1; print(importlib.util.find_spec('module_1').origin)"))
and it's missing. Now, the issue is that in my CI, which runs in a docker image with a fresh clone of the repository, it's present. I also tried to clone the repository under a new path in my local machine and by running hatch shell and checking with the previous command I can see that there the py.typed file for "module_1" is installed.
However if I fully remove and then clone the repository at the same path I can see that the environment gets recreated with the same ID (@ $HOME/.local/share/hatch/env/virtual/myproject/2BSC15rG/) and the issue persists (I obviously tried to remove that folder by hand, remove the environments, and so on).
Is it due to some internal caching mechanism of hatch? How can I "force" a reinstall of those modules?