Skip to content

An agent on a CLI older than its installed skill improvises with basic commands instead of stopping and telling the user to update #4203

Closed

Description

@malibio

Overview

The NodeSpace skill file an agent reads can be newer than the nodespace CLI on the machine. When it is, nothing tells the agent. In a user trial, an agent on CLI 0.2.8 with a current skill noticed the mismatch, then carried on with "the basic commands", could not fetch the workspace's own instructions, and wrote a document into NodeSpace incorrectly.

Problem Statement

From a transcript of an external agent (Claude) in a user's trial:

What exists today:

Proposed Solution

  1. The skill file tells the agent to check the CLI version first, and to stop and tell the user to update NodeSpace when it is below what the skill needs. It must not fall back to older commands, and it must not upgrade the CLI itself (consistent with the file's existing rule about installers). The minimum is stamped into the skill at build time, so the skill and its CLI requirement come from one revision and cannot drift.
  2. The CLI compares its version with the daemon's and prints a clear "update needed" error on a mismatch, so a stale CLI says so on its own, including when no skill is involved.

Documentation

  • Daemon and CLI Lifecycle - how the daemon and CLI are installed, started and checked; update it with the version comparison.
  • ADR-093 - how coding agents receive the skill and its guidance.
  • ADR-064 - which instruction channel owns what; the version gate belongs in the installed skill file, since an old CLI cannot fetch newer guidance.
  • No prior ADR covers skill-to-CLI version compatibility.

Acceptance Criteria

  • SKILL.md starts with a version check (nodespace --version) and a stated minimum, and tells the agent to stop and ask the user to update when the CLI is older, naming what is missing.
  • The preflight table has a row for a CLI that is too old (for example unrecognized subcommand for a command the skill describes) with the same instruction.
  • The minimum version in the skill is produced by the build from the workspace version; a test fails when the skill's stamped minimum and the CLI's own version cannot satisfy each other.
  • The CLI compares its version with GetDaemonVersion and, on a mismatch, prints a message naming both versions and telling the user to update. A test covers a mismatch and a match.
  • A harness scenario starts an agent with a stub CLI reporting an old version and asserts it stops and tells the user instead of running further commands.
  • The CLI's output and the skill text change, so the skill-guidance acceptance criteria above apply. Prompt snapshots are regenerated if model-facing text moves. Code passes bun run quality:fix; bun run test:changed passes.

Technical Specifications

Reference Files

  • packages/skill/SKILL.md - preflight section and the table of command outcomes
  • packages/cli/src/ - main.rs and the command layer, where the daemon call and its error output live
  • packages/proto/proto/node_service.proto - GetDaemonVersion
  • packages/daemon/src/main.rs - the daemon's --version output

Implementation Details

The skill's required minimum must name a released version and travel with the skill when the skill is installed, since a stale CLI can only receive the file that is already on disk.

Non-Goals

How or whether the app offers to update a CLI found on the user's PATH is a separate product decision and is not part of this issue.

Related Issues

Activity

  1. added
    bug
    on Oct 31, 2026
  2. mstomar125 commented on Nov 2, 2026

    @mstomar125
    Contributor

    A second report of the same trial (Slack thread with Anoop): after a full cleanup and reinstall it is not yet confirmed whether the nodespace on PATH was still 0.2.8, so a stale CLI surviving a reinstall remains a candidate cause. The nodespace diagnostics schema-read error in that transcript is still unexplained; GetAllSchemas is the call that reports it (diagnostics.rs). The separate no-embedding-model search message is filed on its own.

    🤖 Generated with Claude Code

  3. self-assigned this
    on Nov 3, 2026
  4. mstomar125 commented on Nov 3, 2026

    @mstomar125
    Contributor

    Picking this up (sweep drain).

  5. mstomar125 commented on Nov 3, 2026

    @mstomar125
    Contributor

    Merged: SKILL.md starts with a CLI version check and preflight row, the minimum is stamped at build/install time from the workspace version, and the CLI appends update advice when a failed command meets a daemon of a different version; nodespace diagnostics reports both versions. Still open: the stub-CLI harness scenario (needs a live model), regenerating any prompt snapshot that embeds the skill text, and the daemon-and-CLI lifecycle doc update.

    🤖 Generated with Claude Code

  6. mstomar125 commented on Nov 6, 2026

    @mstomar125
    Contributor

    Done in the merged lifecycle doc (docs repo) and the node-creation structure test. The live-model residual is split into #4256.

  7. mstomar125 commented on Nov 6, 2026

    @mstomar125
    Contributor

    Correction to the close comment: the lifecycle doc is in docs PR #139, which is still open and in review at the time of writing; it is not merged yet.

  8. mstomar125 commented on Nov 6, 2026

    @mstomar125
    Contributor

    Update: docs PR #139 is now merged (961ee29), so the lifecycle doc described above is live.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

aibugdeveloper-experience

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions