rc schema silently returns the root schema for an unknown command arg
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 68/100
Línea de trabajo
Start with the rc schema and rc commands --json entry points and reproduce the colon-form and space-separated cases described in the issue. Trace how command arguments are resolved, then add coverage for an unknown or colon-joined argument. Done means invalid input exits non-zero with an error instead of returning the root schema, while the space-separated form still works.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
What happens
rc commands --json emits capability IDs in colon form (apps:create, products:store:plan). rc schema expects space-separated tokens (rc schema apps create). Feeding the colon form back in silently returns the root rc schema with exit code 0 and no error:
rc schema apps create # ✅ returns the apps-create schema
rc schema apps:create # ⚠️ returns the ROOT schema (name: "rc"), exit 0, no error
Why it matters
An agent's natural discovery loop is: run rc commands, copy an identifier, run rc schema <that identifier>. Since rc commands gives colon IDs, the agent pastes apps:create and gets a valid-looking-but-empty root schema. It concludes the command takes no args/flags and either guesses or gives up. The failure is silent, so it's hard to notice.
Found while auditing the AI Toolkit skills: multiple agents hit this independently.
Expected
rc schema <unknown-or-colon-joined-arg> should exit non-zero with an error (e.g. "unknown command: apps:create; did you mean apps create?") rather than falling back to the root schema.
Workaround / note
rc schema apps create(space form) works correctly.rc commands --schemas --jsonreturns per-command detail for everything in one call and is the more reliable agent path.
Low severity (a doc/UX papercut, not data loss), but it defeats the primary "ask the binary" discovery flow for agents.
- Lenguaje dominante
- Go
- Estrellas
- 16
- Forks
- 0
- Merge medio
- 1 d 1 h
- PR fusionados (30 d)
- 27
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Issues similares
-
nix: vendorHash is outdated Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 90/100
-
Bob Shell support Abiertoenhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
santhosh-tekuri/jsonschema#276 ·