Skip to content

[33mRunning before_session hook: bun scripts/load-secrets.ts[0m before_session hook injected 4 environment variable(s). Current version: 4.22.0 Checking for updates... Update available: 4.22.0 β†’ 4.24.0 Updating agentv using npm (global install)... changed 160 packages in 15s 37 packages are looking for funding run npm fund for details [33mRunning before_session hook: bun scripts/load-secrets.ts[0m 4.24.0 Update complete: 4.22.0 β†’ [33mRunning before_session hook: bun scripts/load-secrets.ts[0m 4.24.0 fails with 'npm not found' when npm is installed but not on PATH in the current shellΒ #1192

@christso

Description

@christso

Summary

agentv self update can fail with npm not found when AgentV was installed with npm but the current shell has a stripped PATH.

Environment

  • OS: Windows 11
  • Shell: PowerShell via VS Code extension host terminal
  • agentv: 4.22.0 -> 4.24.0
  • Install method: npm install -g agentv
  • npm is installed and works in a normal PowerShell session

Reproduction

  1. Install AgentV globally with npm.
  2. Launch a shell where agentv is available but npm is not on PATH.
  3. Run agentv self update.

Actual

The update starts, detects npm, then fails with:

Error: npm not found. Try using --bun flag.

Expected

The updater should resolve npm relative to the current Node installation or AgentV install location instead of relying only on the shell PATH.

Notes

Using --bun is not a good workaround for an npm-managed install because it creates a second installation managed by a different package manager.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions