Auto-detection of Elasticsearch and Kibana version being used
Los mantenedores suelen responder en 1 día
@JoshMock ya está trabajando en esto.
Desde el 13/10/2026.
Evaluación
Este issue todavía no se ha evaluado.
Descripción
Following the work done in #530, the CLI should be able to auto-detect what versions of Elasticsearch and Kibana it is targeting, so that the commands and flags exposed align with what features are available in that version.
Requirements
elasticsearch.versionandkibana.versiontype changes from a semverstringtostring | { value: string, checked_ts: string }wherevalueis the semver string (orserverless), andchecked_tsis an ISO 8601 datetime string describing when that version was last checked.- The first time a CLI command is issued targeting an Elasticsearch or Kibana instance that has no
versionvalue set in its config file, it fetches the version first (GET /for Elasticsearch,GET /api/statusfor Kibana), setting it in the config using the{ value, checked_ts }form. Once the sniff is complete, the original command runs as normal, with commands filtered for the detected version. - Running
elastic statusalso sniffs and sets the sameversioninformation. - If
checked_tscontains a date more than 30 days in the past, re-run the sniff and update the values. - A
versionset as a plain string is treated as user-pinned: it is never sniffed, refreshed, or overwritten. Only the{ value, checked_ts }form expires. - An optional top-level
detect_version: booleankey (applies to all contexts) controls detection. Defaults totrue. If set tofalse, always skip the sniff step even if aversionvalue is not set. - If the config file is not writable, the sniff step should be skipped.
Implementation details
- Timing: the sniff runs during early config loading, before command registration, so availability filtering uses the detected version on the same invocation.
- Skipped modes: never sniff on
--helpor--dry-run. - Credentials: secrets (including
$(cmd:...)expressions) are resolved early only when a sniff is actually due. Invocations that do not need a sniff keep the current behavior from #706 (no early secret resolution). - Writing the config: update only the
contexts.<name>.<service>.versionnode usingyaml'sparseDocument, preserving the user's comments and formatting. Do not round-trip throughwriteConfig/serializeConfig, which drops comments. - Sniff failure (network error, 401, 404, unparseable response): fail open. Print a one-line warning to stderr (suppressed with
--json), continue without a version (all commands available), and write nothing. The next invocation retries. - HTTP: sniff requests set
redirect: 'error', like the other credentialed requests.
authored by Pi Coding Agent (Claude Opus 5.5)
- Lenguaje dominante
- TypeScript
- Estrellas
- 49
- Forks
- 27
- Merge medio
- 1 d 18 h
- PR fusionados (30 d)
- 65
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la 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.
Más de elastic/cli
-
feat: ship skills/elastic/SKILL.md for agent invocationPosiblemente ocupada @onatozmenn la tomó hace 17 días. Abiertoenhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
elastic/cli#628 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
elastic/cli#617 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Upgrade @elastic/schemas to latestPosiblemente ocupada @JoshMock la tomó hace 1 día. Abiertoauto-pr
elastic/cli#767 · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 58/100
Los mantenedores suelen responder en 1 día
-
Dificultad 3/5 Medio día Aptitud para principiantes 62/100
Los mantenedores suelen responder en 1 día
Todos los issues de elastic/cli
Issues similares
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
dsh-market/dsh-market#877 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
stellar/stellar-dev-skill#151 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
Los mantenedores suelen responder en 1 día
-
Trial & Error: guided Blind offer squeezes on phones and sits under the touch toolbar on iPadAbiertoarea:arcade game ready-for-agent
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
fderuiter/deruiter.dev#2281 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
scope: data grid type: bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 2 días