[PROPOSAL] Add versioned REST API endpoints for test results for NG frontend
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
Direzione di ricerca
Inizia esaminando la logica esistente del modello e del controller, quindi determina come il blueprint mod_api proposto si inserisce nell’applicazione. Aggiungi gli endpoint versionati per i risultati dei test e le categorie, con risposte JSON coerenti e la gestione dei test mancanti. Aggiungi test di integrazione per i casi di successo e di risorsa non trovata in tests/test_api/ ed esegui la suite di test nose2.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
[PROPOSAL] Add versioned REST API endpoints for test results to support Sample Platform NG frontend
Problem
The current platform primarily serves HTML pages and has very limited API surface. The NG frontend direction needs stable, versioned JSON endpoints for test summary/results/files/progress and category metadata.
Proposed endpoints
GET /api/v1/tests/<id>/summaryGET /api/v1/tests/<id>/resultsGET /api/v1/tests/<id>/filesGET /api/v1/tests/<id>/progressGET /api/v1/categories
Proposed implementation notes
- Introduce a dedicated
mod_apiblueprint. - Reuse existing model/controller logic where possible to avoid behavior drift.
- Return structured JSON with consistent status envelope and 404 handling for missing tests.
- Add focused API tests for success and not-found paths.
Why this is valuable
- Unblocks frontend/API decoupling for NG work.
- Creates a clear contract for external consumers and automation.
- Reduces coupling to server-rendered templates.
Verification plan
- Add integration tests under
tests/test_api/. - Validate endpoint behavior locally with
nose2test suite.
In raising this issue, I confirm the following (please check boxes, eg [X]):
- I have read and understood the contributors guide.
- I have checked that the bug-fix I am reporting can be replicated, or that the feature I am suggesting isn't already present.
- I have checked that the issue I'm posting isn't already reported.
- I have checked that the issue I'm posting isn't already solved and no duplicates exist in closed issues and in opened issues
- I have checked the pull requests tab for existing solutions/implementations to my issue/suggestion.
My familiarity with the project is as follows (check one, eg [X]):
- I have never visited/used the platform.
- I have used the platform just a couple of times.
- I have used the platform extensively, but have not contributed previously.
- I am an active contributor to the platform.
- Lingua principale
- Python
- Stelle
- 30
- Fork
- 85
- Merge medio
- 6g 8h
- PR unite (30g)
- 22
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 CCExtractor/sample-platform
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
CCExtractor/sample-platform#1194 · 1 commento ·
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 84/100
CCExtractor/sample-platform#1192 ·
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 42/100
CCExtractor/sample-platform#1082 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
CCExtractor/sample-platform#1079 ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
CCExtractor/sample-platform#1062 · 2 commenti ·
Tutte le issue di CCExtractor/sample-platform
Issue simili
-
area: harness bug status: needs-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
Human-Agent-Society/reef#625 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 80/100
learningequality/kolibri#15351 · 2 commenti ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
Name consistency Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
eellak/triplestore#65 · 1 commento ·