[Schema Inaccuracy] Schema says array of objects, but response had a null value in the array alongside the objects
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 48/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Ferma
- Stack tecnologico
- openapi
- Ambito
- api
Direzione di ricerca
Individua la descrizione OpenAPI dell’endpoint List Public Repositories ed esamina lo schema dell’array di risposta confrontandolo con l’esempio documentato. Aggiorna lo schema in modo che i suoi items consentano sia oggetti repository minimi sia null, quindi verifica che la descrizione dell’endpoint corrisponda alla risposta riprodotta.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Schema Inaccuracy
https://docs.github.com/en/rest/repos/repos?apiVersion=2022-11-28#list-public-repositories
The List Public Repositories endpoint is supposed to return an array of minimal repository objects.
One of the values in such a response at a certain offset was null instead of a minimal repository object.
Expected
Schema should specify that array may contain null values and minimal repository objects, rather than only saying that it contains minimal repository objects.
Reproduction Steps
curl -i "https://api.github.com/repositories?since=263175046"
HTTP/1.1 200 OK
Date: Thu, 13 Feb 2025 06:21:57 GMT
Content-Type: application/json; charset=utf-8
Cache-Control: public, max-age=60, s-maxage=60
Vary: Accept,Accept-Encoding, Accept, X-Requested-With
ETag: W/"94f54685d2f34d4b33402468be31a060f63dbbe9842c0d0294064dc2805f8454"
X-GitHub-Media-Type: github.v3; format=json
Link: <https://api.github.com/repositories?since=263175278>; rel="next", <https://api.github.com/repositories{?since}>; rel="first"
x-github-api-version-selected: 2022-11-28
# …
X-GitHub-Request-Id: D170:2F4C71:38ABFF0:3A8CE3C:67AD8F86
[
{
"id": 263175047,
"node_id": "MDEwOlJlcG9zaXRvcnkyNjMxNzUwNDc=",
"name": "design-patterns-php",
"full_name": "ninja-tn/design-patterns-php",
"private": false,
# …
"deployments_url": "https://api.github.com/repos/ninja-tn/design-patterns-php/deployments"
},
# …
# many lines more, omitted for brevity
# …
{
"id": 263175062,
"node_id": "MDEwOlJlcG9zaXRvcnkyNjMxNzUwNjI=",
"name": "38671075_60",
"full_name": "offlinesite/38671075_60",
"private": false,
# …
"deployments_url": "https://api.github.com/repos/offlinesite/38671075_60/deployments"
},
null,
{
"id": 263175064,
"node_id": "MDEwOlJlcG9zaXRvcnkyNjMxNzUwNjQ=",
"name": "onLlineBooks",
"full_name": "crisantus/onLlineBooks",
"private": false,
# …
"deployments_url": "https://api.github.com/repos/crisantus/onLlineBooks/deployments"
}
# …
# many lines more, omitted for brevity
# …
]
There between object with id 263175062 and object with id 263175064 is a null instead of a minimal repository object.
- Lingua principale
- Nessun dato sulla lingua
- Stelle
- 1.6k
- Fork
- 342
- Merge medio
- 2h 23m
- PR unite (30g)
- 57
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di github/rest-api-description
-
feature
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
github/rest-api-description#7220 ·
-
feature
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
github/rest-api-description#7201 ·
-
feature
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
github/rest-api-description#7163 ·
-
Runner deprecations: registration_deprecates_at is declared on the response but never returned Apertafeature
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
github/rest-api-description#7162 ·
-
feature
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
github/rest-api-description#7135 ·
Tutte le issue di github/rest-api-description
Issue simili
-
enhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
canonical/paas-charm#368 · 1 commento ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
tech debt
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
area:workflow bug ready-for-agent
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
fil-donadoni/tolaria#4409 ·
-
status/awaiting_triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100