`iris_doc mode=list` fails with HTTP 400 for `category` MAC/INT/INC and for the default `ALL`: Atelier `docnames/:cat` only accepts `*`, `CLS`, `RTN`, `CSP`, `OTH`
I maintainer di solito rispondono entro 2 giorni
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 78/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- rust
- Ambito
- backend-api-design
Direzione di ricerca
Inizia da crates/iris-agentic-dev-core/src/tools/doc.rs, in particolare da fetch_docnames_for_cat, dalla mappatura delle categorie e dal ciclo ALL. Confronta queste requests con le route docnames documentate di Atelier, quindi esegui un test di regressione IRIS live per le categorie predefinite ALL e MAC/INT/INC. Il lavoro è completato quando le requests valide di tipo routine hanno esito positivo e ALL conserva o segnala chiaramente i risultati delle categorie quando una request fallisce.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Environment
- iris-agentic-dev v1.3.0 (same code in v1.4.2 and on
masterat5f38c46) - Windows 11, IRIS for Health 2026.1 (Build 235U), Atelier REST through the web server on port 80
- MCP mode, connection from
.iris-agentic-dev.toml
Symptom
iris_doc with mode="list" works only when category="CLS" is passed explicitly:
| Call | Result |
|---|---|
{"mode":"list","pattern":"MyPkg.*","namespace":"<NS>"} (default category ALL) |
{"error":"failed to fetch MAC docnames: HTTP 400 Bad Request","error_code":"SERVER_ERROR","success":false} |
same with "category":"MAC" / "INT" / "INC" |
failed to fetch MAC/INT/INC docnames: HTTP 400 Bad Request |
same with "category":"CLS" |
OK, lists the matching classes |
Because ALL is the default, any list call without an explicit category fails, and MAC/INT/INC can never work.
Root cause
fetch_docnames_for_cat builds /docnames/{cat} with cat in CLS, MAC, INT, INC
(doc.rs#L1704-L1726, and the category mapping at
#L1744-L1766).
In the Atelier API, MAC, INT and INC are types inside the RTN category, not categories. The route
is GET /api/atelier/v1/:namespace/docnames/:cat/:type, and %Api.Atelier.v1:GetDocNames (identical in v2 and
v8 on 2026.1) rejects any other :cat with 400:
Set pCat=$zcvt(pCat,"U")
If ",*,CLS,RTN,CSP,OTH,"'[(","_pCat_",") {
Set %response.Status=..#HTTP400BADREQUEST
In addition, the ALL loop returns on the first failing category
(#L1780-L1791),
so the CLS results already fetched are discarded.
Reproduction without the tool
Plain GET with Basic auth against the same instance and namespace:
| Request | HTTP | documents |
|---|---|---|
/api/atelier/v1/<NS>/docnames/CLS |
200 | 13610 |
/api/atelier/v1/<NS>/docnames/MAC |
400 | |
/api/atelier/v1/<NS>/docnames/INT |
400 | |
/api/atelier/v1/<NS>/docnames/INC |
400 | |
/api/atelier/v1/<NS>/docnames/XYZ (invalid on purpose) |
400 | |
/api/atelier/v1/<NS>/docnames/RTN/MAC |
200 | 6 |
/api/atelier/v1/<NS>/docnames/RTN/INT |
200 | 20 |
/api/atelier/v1/<NS>/docnames/RTN/INC |
200 | 364 |
/api/atelier/v1/<NS>/docnames/RTN/MAC,INT,INC |
200 | 390 (= 6 + 20 + 364) |
Suggested fix
- Map
MAC→/docnames/RTN/MAC,INT→/docnames/RTN/INT,INC→/docnames/RTN/INC. ForALL, one call to
/docnames/CLSplus one to/docnames/RTN/MAC,INT,INCis enough. - Do not throw away the successful categories when one fails in
ALL: return what was fetched and report the
failing category, or fail with a message that says which request was rejected. - A regression test for
listwithoutcategory(and withMAC/INT/INC) against a live IRIS would catch it.
Workaround
Always pass "category":"CLS" for classes. For routines and include files there is currently no working list
mode.
- Lingua principale
- Rust
- Stelle
- 45
- Fork
- 17
- Merge medio
- 2g 11h
- PR unite (30g)
- 15
Preparare l'ambiente
- Include un Dockerfile o un 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 intersystems-community/iris-agentic-dev
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 86/100
intersystems-community/iris-agentic-dev#167 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
intersystems-community/iris-agentic-dev#165 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
intersystems-community/iris-agentic-dev#139 ·
I maintainer di solito rispondono entro 2 giorni
-
Add a CHANGELOG.mdAperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 72/100
intersystems-community/iris-agentic-dev#136 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 3/5 Mezza giornata Idoneità per principianti 45/100
intersystems-community/iris-agentic-dev#146 ·
I maintainer di solito rispondono entro 2 giorni
Tutte le issue di intersystems-community/iris-agentic-dev
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
RustCrypto/utils#1597 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
Non-`main` default branchesAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
max-sixty/worktrunk#4727 · 7 commenti · 1 reazione ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 86/100
I maintainer di solito rispondono entro 1 giorno
-
follow-up
Difficoltà 2/5 1-3 ore Idoneità per principianti 73/100
carrick-sh/carrick#1859 ·
I maintainer di solito rispondono entro 1 giorno