nodeSolidServer / nodeSolidServer/node-solid-server
Globbing should return 200 OK even if empty
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- JavaScript
- Sterne
- 1.8k
- Forks
- 308
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
Assuming I have a container named /notes in my POD and this container contains resources matching /notes/note-* I get a nice list of those resources if I do a GET of /notes/note-*.
But if the /notes container is empty and I try GET /notes/note-* I get 404 - not found.
If think that is wrong, The container is there and any attempt to get a filtered list of its content should return 200 OK since the list is there (the container exists) but it is simply empty as there are no matching resources in the container.
Returning 404 tells the client "You made a mistake - there is nothing here". But the client did not make a mistake - it simply asked for an empty list, not a missing-non-existing list.
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Beginne damit, die GET-Verarbeitung des Servers für Glob-Anfragen wie /notes/note-* nachzuverfolgen und die Fälle einer vorhandenen Ressource und eines leeren Containers zu vergleichen. Überprüfe, wie ein leerer Treffer in einen 404 umgewandelt wird, und füge anschließend Tests hinzu, die zeigen, dass ein vorhandener Container ohne passende Ressourcen 200 OK mit einer leeren Liste zurückgibt.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- javascript
- Bereich
- api, backend
- Issue-Typ
- Bug
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 35/100