I'm hitting an error with `generate-lockfiles` on ...
# general
b
I'm hitting an error with
generate-lockfiles
on a specific package publicly available via pypi (
lexid
) - I'm trying to figure out how to debug this and not having much luck. I searched slack history and other times this has come up has been around private packages, so this seems different. I have a repo up with an isolated minimal test case https://github.com/rhysyngsun/pants-lexid-test, but the short of it is
python_requirement(requirements=["lexid"])
is enough to trigger it. I'll throw the stacktrace I'm getting in a threaded response to this message.
stacktrace.txt
Also I've seen this under both 2.14.1 and 2.15.0rc5
oh, ok, this looks like it's actually coming from the
pip
library
e
Nope - Pex is at fault. You can work around with "lexid>2020.1003" - the 2 older versions have wheels with
pypy27
wheel tags that trip up some patching of Pip that Pex uses to perform locks: https://pypi.org/project/lexid/2020.1003/#history
I'll file a Pex issue shortly.
Actually, that doesn't work around. The parsing of links is aggressive and Pex gets tripped up anyhow. I'll be doing a Pex release today or tomorrow with another fix anyhow; so you'll have to wait on that or use a vcs URL.
b
yeah, neither does
lexid==2021.1006
seem to help
thanks! I can manage with the vcs url in the meantime, feel free to ping me if I can help test out a fix
e
FWICT the latest release on PyPI is
lexid @ git+<https://github.com/mbarkhau/lexid@1334ace84f67f59d93a96b9bf0a4953fb7a15da6>
@big-fall-51153 I'll give you `pants.toml`config to test out 2.1.123 as soon as I release it. The integration test will cover this well enough I'll feel confident in release 1st, have you test after.
Thanks for the report!
👍 1
Ok, that took a while! @big-fall-51153 the
pants.toml
config to try out the fix in your current Pants version is:
Copy code
[pex-cli]
version = "v2.1.123"
known_versions = [
    "v2.1.123|linux_arm64|3a2cba02946eb8859393906673bb56ecf6ebee72961bc8f3ca1ae754493733c6|4076395",
    "v2.1.123|linux_x86_64|3a2cba02946eb8859393906673bb56ecf6ebee72961bc8f3ca1ae754493733c6|4076395",
    "v2.1.123|macos_arm64|3a2cba02946eb8859393906673bb56ecf6ebee72961bc8f3ca1ae754493733c6|4076395",
    "v2.1.123|macos_x86_64|3a2cba02946eb8859393906673bb56ecf6ebee72961bc8f3ca1ae754493733c6|4076395",
]
Pants 2.16.x is being upgraded to Pex 2.1.123 here: https://github.com/pantsbuild/pants/pull/18341
b
@enough-analyst-54434 I can confirm that worked (pants 2.15.0rc5)
e
Excellent. Thanks for testing it out.
That Pex (or newer) will be the default in Pants 2.16.x, at which point you can kill that custom config snippet.
b
thanks!