chore(api): one `plane_500()` helper for reproduced 500s; compat parity scoped to the acceptance list
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 5/5
- Tempo estimado
- Mais de uma semana
- Facilidade para iniciantes
- 25/100
Direção de pesquisa
Start with the Plane 500 response behavior in crates/thrust-api/src/lib.rs and the referenced pinned Plane handlers to confirm the three exact bodies. Then review the acceptance list and fixtures under tests/parity/fixtures/; done means the helper, parity and contract checks, route set, and oracle expectations all meet the listed criteria. This issue is blocked by #44 and spans API behavior, tests, and oracle data.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Context
The shared router answers every internal failure with one Thrust-shaped body: CoreError::Internal becomes 500 {"error":{"code":"internal","message":"internal error"}} (crates/thrust-api/src/lib.rs:47-48,61), and the real cause travels only in the InternalErrorDetail response extension that the root logs (crates/thrust-api/src/lib.rs:34-37,69-71, crates/thrust-worker/src/lib.rs:156-158). No compat-plane crate exists yet; it arrives with #44. The round-27 owner decision is to reproduce all of Plane's 500 responses (research/0007 line 7; DEVIATIONS C-1, DEVIATIONS.md:27,31), and ADR-0031 (round 27, line 74) reads "reproduce" as the same status and body returned as a deliberate, handled error, never a crash of the process.
Problem
- Plane has three different 500 texts, and the text is part of the contract (
research/0007PQ-409, line 213; line 201). Atoracle/v1-pin-20261018:{"error":"Something went wrong please try again later"}from the base handlers (apps/api/plane/api/views/base.py:107,apps/api/plane/app/views/base.py:107),{"error":"An unexpected error occurred"}on project create (apps/api/plane/api/views/project.py:320,337),{"error":"Internal server error"}on the generic asset GET (apps/api/plane/api/views/asset.py:474). - The 500 set is larger than EX-001/EX-002 (ADR-0122 round 27, line 94). Without one helper each handler builds its own body, or reproduces the crash itself, which costs a failed request and an instance reset (
research/0004§7). - The oracle register still says
rust_expectation: fixfor EX-001 and EX-002 (oracle/exceptions.yaml:68,89on the Plane fork branchfeat/plane-b6a-upstream-sync-oracle), which round 27 superseded. - The parity obligation is unbounded:
research/0007counts 157 quirks, 53 breaks-clients, 93 affects-parity-tests and 11 informational (lines 38-49), every v1 and compat entry defaulting toreproduce; F-X13 still names the 290 P0 rows (FEATURES.md:137).
Proposal
plane_500(kind: Plane500, cause: impl Into<String>) -> Response<Body>in the crate that holds the Plane-shaped types (#52), used by compat-plane and/api/v1.enum Plane500 { SomethingWentWrong, UnexpectedError, InternalServerError }with the bytes copied from the pin. It sets the status, writes the exact body and attachesInternalErrorDetail(cause), so the cause is logged and never returned.- Every reproduced 500 calls it. No handler writes
StatusCode::INTERNAL_SERVER_ERRORitself or panics to produce a 500. - Parity scope (FR-18 (2)): the compat-plane oracle and replay obligation is the F-X13 acceptance list as revised in round 29 (the 48-route slice from #44 plus the M2 screens from #46). A quirk on a route outside the list is not a test obligation until the route joins the list. Breaks-clients quirks on routes in the list get a test home (TH-corpus, TH-gate, TH-replay or TH-unit,
research/0007line 36). - Edit EX-001 and EX-002 to
rust_expectation: reproduceon the oracle branch. - Out of scope: FR-18 (3) audit logging at P1 and (4) flags as a table. Those are the Track A tier edits (FEATURES F-E06, F-E00a; ADR-0048 and ADR-0008, round-29 notes).
Acceptance criteria
-
parity_plane_500_bodiescompares eachPlane500variant's status and body bytes with fixtures undertests/parity/fixtures/taken from the oracle (oracle/corpus/assets.json#workspace-asset-uploadfor the base text, the pinned source for the other two). Changing one byte of a fixture makes it fail (control). -
grep -rn "INTERNAL_SERVER_ERROR"over the compat-plane and/api/v1sources matches only the helper. - A contract test reproduces one recorded 500 on a route in the acceptance list (for example
per_page=0, PQ-402) on all four targets: status 500, the exact Plane body, and the next request to the same target succeeds. - The compat replay and oracle route set is generated from the acceptance list, and
comm -3of the two sorted lists is empty. -
oracle/exceptions.yamlEX-001 and EX-002 readrust_expectation: reproduce.
References
- Review: .agents/plans/contrail/reviews/2026-10-19-fable-architecture-review.md (FR-18)
research/0007-plane-quirks-catalog.mdlines 7, 9, 36, 38-49, 201, 213 (PQ-409), 206 (PQ-402)- ADR-0031 (round 27, line 74), ADR-0034 (round 27 tripwires, line 68), ADR-0122 (line 94), ADR-0006 panic policy
DEVIATIONS.md:27,31(C-1);FEATURES.md:137(F-X13)crates/thrust-api/src/lib.rs:34-37,47-48,61,69-71- Plane at
oracle/v1-pin-20261018:apps/api/plane/api/views/base.py:107,apps/api/plane/app/views/base.py:107,apps/api/plane/api/views/project.py:320,337,apps/api/plane/api/views/asset.py:474; oracle branchoracle/exceptions.yaml:45-89
Blocked by: #44
Finding: FR-18
- Linguagem predominante
- Rust
- Estrelas
- 0
- Forks
- 0
- Merge médio
- 1h 35min
- PRs com merge (30d)
- 67
Preparar o ambiente
- Sem Dockerfile nem arquivo Docker Compose
- Sem modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de aRustyDev/thrust
-
area:process prio:p1 type:security
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 48/100
Mantenedores costumam responder em até 1 dia
-
area:process bug prio:p1
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 38/100
Mantenedores costumam responder em até 1 dia
-
area:process prio:p1
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 55/100
Mantenedores costumam responder em até 1 dia
-
area:process prio:p1
Dificuldade 4/5 1-2 dias Facilidade para iniciantes 55/100
Mantenedores costumam responder em até 1 dia
-
area:process prio:p1
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 56/100
Mantenedores costumam responder em até 1 dia
Todas as issues de aRustyDev/thrust
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
Mantenedores costumam responder em até 1 dia
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
-
Clean master build fails in zune-jpeg error conversion and zero-IV array construction (patch)Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
CakeRepository/agentshangout#995 ·
-
area:frontend kind:bug priority:p3 ready
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 88/100
Mantenedores costumam responder em até 1 dia