-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stop publishing to PyPI #1654
Comments
@asottile-sentry Can you elaborate on (1) and (2) for us? It's not obvious to me the connection between publishing to PyPI and these two reasons. 🐭 |
for (1) a lot of our javascript build and packaging depends on setuptools command which are deprecated. not only that, invoking them through as far as I can tell from the history, being pypi-installable was how we used to deploy sentry but that's no longer the case -- it gets very few public downloads and presumably are all either mistakes for as for the setuptools breakage -- the js build and layout currently makes a bunch of assumptions about disk layout and the changes in setuptools 64 break those assumptions (and the build) if we could stop publishing it would eliminate a bunch of the complexity around the build, have some ~small speedup to development setup time, and potentially allow us to reorganize our dockerfiles to build faster my proposal for deprecation is:
|
If we yank and people install will they still be able to install but with our deprecation message, or (as I suspect) will they not be able to install at all? What alternative would we guide them towards? |
the last time I tried this the following happens when you yank every version: pip install whatever==1.2.3 # succeeds, shows message
pip install whatever>=1.2.3 # errors, no versions avaialable
pip install whatever # errors, no versions available |
for example: $ pip install --no-deps -i https://test.pypi.org/simple aspy.yaml
Looking in indexes: https://test.pypi.org/simple
ERROR: Could not find a version that satisfies the requirement aspy.yaml (from versions: 0.2.0, 1.3.0)
ERROR: No matching distribution found for aspy.yaml
$ pip install --no-deps -i https://test.pypi.org/simple aspy.yaml>=1.3.0
ERROR: Could not find a version that satisfies the requirement aspy.yaml (from versions: 0.2.0, 1.3.0)
ERROR: No matching distribution found for aspy.yaml
$ pip install --no-deps -i https://test.pypi.org/simple aspy.yaml==1.3.0
Looking in indexes: https://test.pypi.org/simple
Collecting aspy.yaml==1.3.0
Downloading https://test-files.pythonhosted.org/packages/99/ce/78be097b00817ccf02deaf481eb7a603eecee6fa216e82fa7848cd265449/aspy.yaml-1.3.0-py2.py3-none-any.whl (3.5 kB)
WARNING: The candidate selected for download or install is a yanked version: 'aspy-yaml' candidate (version 1.3.0 at https://test-files.pythonhosted.org/packages/99/ce/78be097b00817ccf02deaf481eb7a603eecee6fa216e82fa7848cd265449/aspy.yaml-1.3.0-py2.py3-none-any.whl#sha256=463372c043f70160a9ec950c3f1e4c3a82db5fca01d334b6bc89c7164d744bdc (from https://test.pypi.org/simple/aspy-yaml/) (requires-python:>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*))
Reason for being yanked: hi there
Installing collected packages: aspy.yaml
Successfully installed aspy.yaml-1.3.0 |
Interesting. So we could guide people to use the pinned version as their workaround. Seems reasonable. If we wanted to be really gentle with this we could continue publishing packages for a while (three months?) but update our automation to immediately yank after publishing. What's the long-term migration path for anyone still using this package? Switch to |
either of those, yes -- I actually don't think the pypi package is even usable on its own right now 😆 |
How much space do we get for the warning message? What does the input look like? Output? |
in the above example the "hi there" is the yank message -- afaict there's no limit on it: https://github.com/pypi/warehouse/blob/a3d6221d4c692569e2290f6d75a75b4db747335b/warehouse/packaging/models.py#L468 |
Copy draft. Thoughts? WarningThis is for if we go the publish-and-immediately-yank route for a time. We would update the pin version in the tl;dr.
Error
|
I'm not sure we'll have much control over the newlines and whitespace -- and we only get one message for the warning case but otherwise looks good |
Meaning we can't update the message with the new version numbers as they come out? |
we get an error message per package so we can use the right one for each |
Okay it sounds like we've gone far enough with this for now, and we can revisit during the next calver release. Ya? |
oh I want to set the yank messages now so that we're ready to turn it off for the next calver release :D |
From @Disservin in Discord, who uses the PyPI package:
|
Where do we enter the message? Is it after I click "Yank"? I'm afraid to click it. 😅 Also, there are 354 versions of |
I added brief notes to the ticket description about migration options. Is there an unyank operation? Is it possible to change the yank message after yanking once? |
yeah the message will be entered after that -- yanking is entirely reversible which is why we're approaching from that angle rather than deleting. the message can be changed yes (idk if there's a modify but you can unyank and reyank) I can write up a script for this 👍 as for using the current pypi bundle, I'm curious how because as far as I can tell it doesn't have all the parts needed to execute |
This issue has gone three weeks without activity. In another week, I will close it. But! If you comment or otherwise update it, I will reset the clock, and if you label it "A weed is but an unloved flower." ― Ella Wheeler Wilcox 🥀 |
I logged into PyPI and used Chrome's Copy > as cURL feature to prepare the script below. I copied and pasted from PyPI's web UI to get a list of version numbers and then cleaned it up in Vim as #!/usr/bin/env zsh
for version in $(cat all-versions.txt); do
echo "🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺🌺"
echo "Yanking $version ..."
curl "https://pypi.org/manage/project/sentry/release/$version/" \
-H 'authority: pypi.org' \
-H 'accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7' \
-H 'accept-language: en-US,en;q=0.9' \
-H 'cache-control: max-age=0' \
-H 'content-type: application/x-www-form-urlencoded' \
-H 'cookie: nerp' \
-H 'origin: https://pypi.org' \
-H 'referer: https://pypi.org/manage/project/sentry/releases/' \
-H 'sec-ch-ua: "Not/A)Brand";v="99", "Google Chrome";v="115", "Chromium";v="115"' \
-H 'sec-ch-ua-mobile: ?0' \
-H 'sec-ch-ua-platform: "macOS"' \
-H 'sec-fetch-dest: document' \
-H 'sec-fetch-mode: navigate' \
-H 'sec-fetch-site: same-origin' \
-H 'sec-fetch-user: ?1' \
-H 'upgrade-insecure-requests: 1' \
-H 'user-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/115.0.0.0 Safari/537.36' \
--data-raw 'csrf_token=derp&yanked_reason=https%3A%2F%2Fgithub.com%2Fgetsentry%2Fself-hosted%2Fissues%2F1654&confirm_yank_version='"$version" \
--compressed
done; |
Is anyone using the https://pypi.org/project/sentry/ package?
We would like to stop publishing it for the following reasons:
setup.py
to make the development flow less painful.setuptools
mysteriously breaks us (like 64.0.0 did).Migration Options
If you have been depending on the
sentry
PyPI package, here are your options:self-hosted
.To Do
The text was updated successfully, but these errors were encountered: