Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Rename 422 from "Unprocessable Entity" to "Unprocessable Content"

Aperta
#664 0 commenti 4 reazioni 0 assegnatari Vedi su GitHub

@mina86 ci sta già lavorando.

Dal 9/2/2023.

  • #588 di @mina86 — aperta
  • #692 di @Pi-Cla — aperta

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
55/100
Tipo di issue
Refactoring
Chiarezza
Specificata chiaramente
Stato di attività
Ferma
Stack tecnologico
rust
Ambito
api

Direzione di ricerca

Inizia leggendo src/status.rs alle righe 456-458, quindi cerca i riferimenti al nome esistente dello stato 422. Il lavoro è completato quando la documentazione dello stato, il nome della costante, la frase del motivo visualizzata e il riferimento all’RFC usano in modo coerente "Unprocessable Content", come descritto nell’issue.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Present State

Currently: status.rs lines 456 to 458:

/// 422 Unprocessable Entity
/// [[RFC4918](https://tools.ietf.org/html/rfc4918)]
(422, UNPROCESSABLE_ENTITY, "Unprocessable Entity");

Recommendation

Use this instead:

/// 422 Unprocessable Content
/// [[RFC9110](https://datatracker.ietf.org/doc/html/rfc9110#section-15.5.21)]
(422, UNPROCESSABLE_CONTENT, "Unprocessable Content")

Relevant RFCs

Both of the following RFCs define 422 but with a one-word difference:

  • RFC 4918, "Proposed Standard", June 2007, "Unprocessable Entity"
  • RFC 9110, "Internet Standard", June 2022, "Unprocessable Content"

Potential Confusion: Even though RFC 9110 it is newer, it does not obsolete RFC 4918 (directly nor transitively).

Arguments in Favor of RFC 9110
  1. RFC 9110 is titled "HTTP Semantics" which is a direct fit for this library, whereas RFC 4918 is scoped to WebDAV.

  2. RFC 9110 is an Internet Standard while RFC 4918 is only a Proposed Standard.

  3. MDN uses RFC 9110 for the 422 status code

  4. RFC 9110 is newer (2022 vs. 2007)

RFC 9110: 422: Unprocessable Content

15.5.21. 422 Unprocessable Content

The 422 (Unprocessable Content) status code indicates that the server understands the content type of the request content (hence a 415 (Unsupported Media Type) status code is inappropriate), and the syntax of the request content is correct, but it was unable to process the contained instructions. For example, this status code can be sent if an XML request content contains well-formed (i.e., syntactically correct), but semantically erroneous XML instructions.

References

Lingua principale
Rust
Stelle
1.4k
Fork
382
Merge medio
10h 32m
PR unite (30g)
2

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di hyperium/http

Tutte le issue di hyperium/http

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.