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

mcp: mock schema is invalid GraphQL, so schema_* tests pass on a parse error

Chiusa
#821 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Una pull request collegata è già stata integrata.

  • #822 di @Starefossen — integrata

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Ferma
Stack tecnologico
go, graphql
Ambito
cli, testing

Direzione di ricerca

Read internal/mcp/client/mock_client.go and the schema_* subtests in internal/mcp/server_test.go. First inspect the mock schema parse failure and how the tests handle tool errors. Define the missing GraphQL types and make the tests fail on tool errors; done when the schema parses and the tests verify successful tool results. An open linked pull request (#822) is already addressing this work.

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

Descrizione

The mock schema in internal/mcp/client/mock_client.go references about 35 types it never defines, for example TeamEnvironment, TeamConnection and Time. Parsing fails with Undefined type TeamEnvironment.

The schema_* subtests in internal/mcp/server_test.go therefore only ever receive the parse error. They still pass because they check for a substring or a non-empty result, and the error text matches. For example, schema_list_queries looks for "me", which appears in "schema".

Fix: define the missing types in the mock, and make the tests fail when a tool returns an error.

Lingua principale
Go
Stelle
2
Fork
5
Merge medio
6h 59m
PR unite (30g)
36

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 nais/cli

Tutte le issue di nais/cli

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.