careful-address-89803
10/06/2022, 11:45 PM"azure-identity": ["azure.identity"]
. The dependency on that package shows up in ./pants dependencies ...
, And the package shows up in the message about which packages it's putting in the pex, and the whl for that package shows up in the pex sandbox. This doesn't seem to be a problem for tests, though, as they run just fine. I'm pretty sure it has something to do with resolves, as some of them work with ./pants run
and others don't. Short of binary-searching my dependencies, is there anything I can do to debug what's going on?careful-address-89803
10/06/2022, 11:46 PMcareful-address-89803
10/07/2022, 12:07 AMenough-analyst-54434
10/07/2022, 12:39 AMazure-nspkg
is one of the rare packages that is titchy wrt to how the venvs it lives in are constructed. Do you use https://www.pantsbuild.org/docs/reference-pex#venv_use_symlinks ? FWICT Pants itself uses the symlink mode for ./pants run
with no way for you to currently override this.careful-address-89803
10/09/2022, 9:35 PM./pants --pex-venv-use-symlinks test ::
causes the tests to fail in the same way.enough-analyst-54434
10/09/2022, 9:38 PMenough-analyst-54434
10/09/2022, 9:39 PMcareful-address-89803
10/09/2022, 9:48 PMenough-analyst-54434
10/09/2022, 9:52 PMcareful-address-89803
10/10/2022, 12:12 AMenough-analyst-54434
10/10/2022, 5:35 PMpex_binary
targets with execution_mode="venv"
set.
In the course of that investigation I found this:
PS C:\Users\John Sirois\Downloads> zipinfo azure_nspkg-2.0.0-py2.py3-none-any.whl | grep __init__
-rw-rw-rw- 2.0 fat 3 b- defN 17-Apr-10 19:06 azure/__init__.py
PS C:\Users\John Sirois\Downloads> unzip -qc azure_nspkg-2.0.0-py2.py3-none-any.whl azure/__init__.py | hexdump -C
00000000 e2 88 a9 e2 95 97 e2 94 90 0d 0a |...........|
0000000b
So the azure_nspkg
__init__.py
is not empty! I guess it works but I have no clue what those bytes are except for the ending \r\n
Windows end of line bytes.enough-analyst-54434
10/10/2022, 7:31 PMazure/__init__.py
, The 2.0.0 version uses the not quite empty strange bytes above and the 3.0.0 version I linked here switches to the `pkgutil`ns package mechanism, but makes sure to restrict that to only Python<3. You might want to get off the Azure 2.0.0 train if possible?enough-analyst-54434
10/10/2022, 7:33 PMcareful-address-89803
10/10/2022, 8:45 PMazuru.azcollection
is the last thing holding us up on that, they haven't really been updating it. Everything seems to work fine by removing the namespace package from my requirements.