Releases API sometimes is not reliable #24725
-
Releases API sometimes works and sometimes doesn’t. Looks like it really depends on how the releases is generated? I’ve met quite a few repos the API doesn’t work. Is there any reason why and how it can be fixed? For example the following query return nothing While different repos works: |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments
-
The GitHub Repository “Releases” page is not just Releases, the interface co-mingles Releases (something you create on GitHub) and Tags (a native git feature). A Tag points to a specific commit and a Release, in turn, points to a Tag, but they’re co-mingled on the interface because for a consumer it is usually the Tag that matters for both a Tag and a Release. If we visit the Releases of openjdk/jtreg we can see that there are many Tags, but no Releases, whereas in the Releases of adoptium/run-aqa we can see there are many Releases. The difference between a Release and a Tag on the interface can be identified based on the style of information present, and the information included. A Release has a large heading, and a sub-heading that reads “@username released this n time ago” whereas a Tag simply displays the Tag and the commit it points to. ReleaseTagIf you’d like to programmatically access a list of tags, there is an endpoint, just replace
You may also find get a release by tag name helpful. |
Beta Was this translation helpful? Give feedback.
-
Thanks @shrink ! That makes sense. Unfortunately using the tag instead of releases can’t assume the tags are in chronological order( in alphabetical order I believe), which makes it difficult to get the latest tag for some repo. |
Beta Was this translation helpful? Give feedback.
-
Will use git command |
Beta Was this translation helpful? Give feedback.
The GitHub Repository “Releases” page is not just Releases, the interface co-mingles Releases (something you create on GitHub) and Tags (a native git feature). A Tag points to a specific commit and a Release, in turn, points to a Tag, but they’re co-mingled on the interface because for a consumer it is usually the Tag that matters for both a Tag and a Release.
If we visit the Releases of openjdk/jtreg we can see that there are many Tags, but no Releases, whereas in the Releases of adoptium/run-aqa we can see there are many Releases.
The difference between a Release and a Tag on the interface can be identified based on the style of information present, and the information included. A Relea…