poetry icon indicating copy to clipboard operation
poetry copied to clipboard

The "releases" key on the pypi JSON API is deprecated

Open dimbleby opened this issue 3 years ago • 5 comments

https://warehouse.pypa.io/api-reference/json.html#project

The releases key on this response should be considered deprecated, and projects should shift to using the simple API (which can be accessed as JSON via PEP 691) to get this information where possible.

In the future, the releases key may be removed from this response.

see PyPiRepository.find_packages() for where poetry currently uses this.

dimbleby avatar Jul 26 '22 09:07 dimbleby

As an alternative to #6081, perhaps someone should petition that this key if deprecated be replaced by something that is useful.

I think a sensible API and poetry's needs are aligned here:

  • it makes perfect sense to remove most of the information in releases, clients that need details for a particular version can go to the version-specific endpoint
  • but removing the capability even to learn what the available versions are seems like overshoot
  • perhaps they would be open to replacing releases with eg versions which would be just a list of the available versions

would #5971 give poetry more weight in such discussions?!

dimbleby avatar Jul 27 '22 09:07 dimbleby

Hi, commenting to bump this one up. This issue is also currently affecting my team's projects.

We recently released a new version of a package developed by us, and we are currently unable to upgrade to it via Poetry. By checking my package on the JSON API I noticed that the latest release is indeed not listed there. But, for example, checking here, the newest release is listed (3.2.3).

Are we close to getting a fix?

Luned avatar Jul 27 '22 12:07 Luned

this issue is not affecting your projects, you are confused with something else. The releases key is not yet removed from the API

dimbleby avatar Jul 27 '22 12:07 dimbleby

Hey, thanks for your answer! I assumed it could be potentially related, since they are deprecating the releases key, there could have been some (accidental) changes on their side which is causing my issue. It could just be a huge coincidence. I checked the pypi github and noticed that some people are reporting the same issue as myself so I am looking closely into that option as well.

Either way, I was just reporting the problem in case it was related and other people came across this, and to follow the issue as well.

Luned avatar Jul 27 '22 13:07 Luned

The JSON API issue is known/ongoing and is/was tracked at pypi/warehouse#11949 -- please see the linked issues there for an explanation and add your voice to the crowd there.

neersighted avatar Jul 27 '22 15:07 neersighted

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

github-actions[bot] avatar Mar 01 '24 11:03 github-actions[bot]