I think we may wanna spend some energy on this `ur...
# development
b
I think we may wanna spend some energy on this
urllib
issue that's come up twice (it doesn't help I am also getting bitten) https://pantsbuild.slack.com/archives/C046T6T9U/p1683574114661669 https://pantsbuild.slack.com/archives/C046T6T9U/p1683215047758389 are existing discussions in #general
We have informally talked about pulling the plug on our anonymous telemetry, Since
humbug
is the one pulling in
requests
(pulling in
urllib3
. Alternatively we can switch
humbug
to be provided in rule-code, and not part of the Pantsbuild environment (similar to
pex
, I believe)
b
imo it would be fine to pull
humbug
. We originally expected it would help us provide better tech support, but it hasn't really panned out for that. If we could substitute in some other telemetry tool, that could be worthwhile. But given that no major value being is being returned to the project and it has unfortunately become a blocker for some users, I think it's time to take humbug out of people's way one way or another.
b
I'm also thinking we might wanna cherry pick to 2.16, since this is biting people. We could help them out sooner than 2.17
h
We shouldn't cherry-pick a deprecation to 2.16. But you could cherry-pick the non-deprecation parts
b
E.g. the removal of behavior?
Well until then, I think I can't upgrade to Pants 2.16 😐
b
Does this violate the deprecation policy though? If users aren't losing any functionality or API that they depend on, and are gaining a bug fix, it seems like that is not a deprecation from a user perspective.
e
Is it understood that this works fine?:
Copy code
jsirois@Gill-Windows:~ $ echo "urllib3<2" > foo.txt
jsirois@Gill-Windows:~ $ rm -r ~/.cache/nce/
jsirois@Gill-Windows:~ $ PIP_CONSTRAINT=foo.txt PANTS_VERSION=2.16.0rc1 pants
Bootstrapping Pants 2.16.0rc1 using cpython 3.9.15
Installing pantsbuild.pants==2.16.0rc1 into a virtual environment at /home/jsirois/.cache/nce/6621291ed4120fa45607b367abf7786ce496f389f27240712a63c31f1c438c21/bindings/venvs/2.16.0rc1
New virtual environment successfully created at /home/jsirois/.cache/nce/6621291ed4120fa45607b367abf7786ce496f389f27240712a63c31f1c438c21/bindings/venvs/2.16.0rc1.
No goals specified.
Use `pants help` to get help.
Use `pants help goals` to list goals.
jsirois@Gill-Windows:~ $ ls -l /home/jsirois/.cache/nce/6621291ed4120fa45607b367abf7786ce496f389f27240712a63c31f1c438c21/bindings/venvs/2.16.0rc1/lib/python3.9/site-packages/ | grep urllib3
drwxr-xr-x  6 jsirois jsirois   4096 May  9 10:08 urllib3
drwxr-xr-x  2 jsirois jsirois   4096 May  9 10:08 urllib3-1.26.15.dist-info
b
And what's the intended way of getting that working with the global
plugins
option?
e
I have no intentions. I'm just pointing out a thing.
b
Ok
e
Further:
Copy code
jsirois@Gill-Windows:~ $ rm -r ~/.cache/nce/
jsirois@Gill-Windows:~ $ echo "PIP_CONSTRAINT=foo.txt" > .env
jsirois@Gill-Windows:~ $ PANTS_VERSION=2.16.0rc1 pants
Bootstrapping Pants 2.16.0rc1 using cpython 3.9.15
Installing pantsbuild.pants==2.16.0rc1 into a virtual environment at /home/jsirois/.cache/nce/6621291ed4120fa45607b367abf7786ce496f389f27240712a63c31f1c438c21/bindings/venvs/2.16.0rc1
New virtual environment successfully created at /home/jsirois/.cache/nce/6621291ed4120fa45607b367abf7786ce496f389f27240712a63c31f1c438c21/bindings/venvs/2.16.0rc1.
No goals specified.
Use `pants help` to get help.
Use `pants help goals` to list goals.
jsirois@Gill-Windows:~ $ ls -l /home/jsirois/.cache/nce/6621291ed4120fa45607b367abf7786ce496f389f27240712a63c31f1c438c21/bindings/venvs/2.16.0rc1/lib/python3.9/site-packages/ | grep urllib3
drwxr-xr-x  6 jsirois jsirois   4096 May  9 10:14 urllib3
drwxr-xr-x  2 jsirois jsirois   4096 May  9 10:14 urllib3-1.26.15.dist-info
So, if that's useful - there you go.
b
That allows me to use
pants help
as a workaround. Unfortunately
PANTS_SOURCE
is afflicted, but I think that's going to be the case even with
humbug
gone, so separate issue
e
I think
PANTS_SOURCE
, which just runs the Pants repo
./pants
script, uses pip install; so the
PIP_*
env var trick should still work.
h
I think it's fine to remove telemetry (most people turn it off anyway), but want to be sure that is the consensus opinion before doing so. I don't think we should backport to 2.16 if we can avoid it.
b
Does an option like adding
urllib3<2
to pants’ requirements work (potentially with BUILD file adjustments to have it come through)? If it does, might that be lower risk/lower impact?
e
Yes, but not retroactively. The
PIP_*
trick is a retroactive workaround for install of a
pantsbuild.pants
distribution without that.
b
Yeah for sure, hence, if that is safer to cherry-pick to 2.15 and 2.16, we’d fix more users sooner, versus removing humbug as the only fix, only in 2.17
e
Ah, gotcha. Decouple humbug issue from urllib3 issue. Sounds sane to me!
👍 1
b
I've proposed that change in https://github.com/pantsbuild/pants/pull/18959 as an option to cherry-pick (and #18952 can thus remain focused on 2.17).
b
You rock
❤️ 1
b
I have a sense we haven't resolved this conversation? • Based on all the s, it seems clear that 18952 has consensus to merge (other than potentially double checking the wheel's deps) • But, it's unclear about whether it'll be cherry-picked. • Thus, I'm unclear on whether to merge/cherry-pick 18959, or just close it as not necessary. I have personally have no point of view, and am happy to go with either plan, but someone will have to let me know 😄
b
I think your PR is cherry pickable, mine isn't
Just to be safe
b