Hey pants team, is there a way to investigate what...
# general
b
Hey pants team, is there a way to investigate what is pulling in a specific wheel file? I have an odd issue I can't seem to track down where a pex I have build (using pants 1.30 and pants 2.13) references a completely different version of a 3rd party module than I have referenced in the BUILD file.
h
Hello! One idea is to inspect the sandbox in 2.13: https://www.pantsbuild.org/docs/troubleshooting#debug-tip-inspect-the-sandbox-with---keep-sandboxes Another idea is if you are using lockfiles? That should pin down the exact artifcats (sdists and wheels) that will be used
b
I do have a lockfile which specified the right version. So the sandbox would have the list of installed_wheels that were brought in during build?
h
So the sandbox would have the list of installed_wheels that were brought in during build?
A Pex is a zip file, so you can
unzip requirements.pex
for example and then look at the PEX-INFO or I think it's a folder called
.deps
iirc
b
Ok. I'll unzip the pex and see what I can find. Is there any way to tell where a specific wheel would've been pulled from once I unpack the pex?
h
So the version that is being pulled into the pex is different than the lockfile one? Or just different than the BUILD file one?
b
The python code is trying to use something different from the lockfile and build file. I haven't had a chance to unpack the pex just yet, will try that momentarily
I unpacked the zip, and the correct version of the package with issues is installed. So that aligns with the build file and lock file.
I think I found a solution, I didn't realize that pants 2.13 would place the pex in an entirely different spot than I had expected, once I unpacked the newly build pex I saw that the proper versions were installed. When I looked at what pants 1.30 had built, it contained the wrong version. I'm going forward with rebuilding my docker file and testing the new pex out