Test aggregator proxy failures and response forwarding
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 74/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- next.js, typescript
- Ambito
- backend-api-design, testing
Direzione di ricerca
Read app/api/aggregator/[...path]/route.ts and tests/api-client.test.ts, then follow CONTRIBUTING.md for the pinned pnpm setup. Add deterministic route-handler tests with mocked upstream fetches for the allowlist, methods, environment selection, forwarding, rejection and error mapping cases in the acceptance criteria. Run lint, typecheck, unit tests and build; done when the tests pass without credentials or external requests.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Problem
The frontend routes browser requests through app/api/aggregator/[...path]/route.ts. Regression coverage must exercise this server boundary, rather than only mocking the browser API client. Related historical issue: #10.
Scope
Add deterministic route-handler tests using mocked upstream fetches. Cover the current endpoint allowlist, method restrictions, environment selection and error mapping. No live network or backend is required.
Acceptance criteria
- Allowed GET requests and POST quotes/prepare requests forward to the expected
/api/v1path with query/body preserved. - Unknown paths, wrong methods, credential-bearing/invalid origins and oversized POST bodies are rejected without an upstream request.
- Missing production configuration returns
NOT_CONFIGURED; upstream failure/non-JSON/redirect responses produce the documented errors. - Upstream status and optional request ID survive forwarding; all responses use
Cache-Control: no-store. - Browser cookies and Authorization headers are not forwarded to the aggregator.
- Tests run in CI without credentials or external requests.
Contributor guidance
Estimated difficulty: medium. Start with the route handler and tests/api-client.test.ts. Follow CONTRIBUTING.md and use Node 22+ with the pinned pnpm version. Submit test results for lint, typecheck, unit tests and build. Keep this PR focused on the proxy boundary.
- Lingua principale
- TypeScript
- Stelle
- 0
- Fork
- 3
- Merge medio
- 19h 38m
- PR unite (30g)
- 36
Preparare l'ambiente
Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi 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 VELTRIXAE/frontend
-
documentation good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
enhancement help wanted
Difficoltà 3/5 1-2 giorni Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di VELTRIXAE/frontend
Issue simili
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 92/100
liberation-data/drivine#826 ·
I maintainer di solito rispondono entro 1 giorno
-
【优化】“打开文件列表”,建议对当前文件进行高对比度标注Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
zhitongblog/solomd#623 ·
I maintainer di solito rispondono entro 1 giorno
-
aufwand: klein documentation Einsteiger-Familie freigegeben Haushalts-Admin
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
I maintainer di solito rispondono entro 1 giorno
-
enhancement frontend
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
openwallet-foundation/eudiplo#1600 ·
-
docs(website): add a GitLab CI/CD button next to the GitHub Action button on the homepageForse già presa @shryssssss-maker l’ha presa oggi. Apertadocumentation enhancement first-timers-only good first issue
Difficoltà 1/5 1-3 ore Idoneità per principianti 88/100
OWASP/cve-lite-cli#1739 · 2 commenti ·
I maintainer di solito rispondono entro 2 giorni