Skip to content

fix(acp): validate workspace access before session admission - #108

Merged
diodeme merged 4 commits into
mainfrom
fix/client-user-feedback
Aug 30, 2026
Merged

diodeme merged 4 commits into
mainfrom
fix/client-user-feedback

Conversation

@Kevin4234

Copy link
Copy Markdown
Collaborator

Background

When a conversation workspace was deleted, moved, or became inaccessible, the ACP adapter still attempted to use it as the working directory and failed with:

failed to start ACP adapter npx.cmd: The directory name is invalid

This made a workspace problem appear to be an npx.cmd or Agent environment failure.

Changes

  • Validate the conversation workspace before creating, rerunning, continuing, recovering, or sending a session:
    • The path exists
    • The path is a directory
    • The directory is accessible
  • Return structured errors:
    • workspace.path-not-found
    • workspace.path-not-directory
    • workspace.path-inaccessible
  • Include projectId and workspacePath in error parameters
  • Add localized Chinese and English error messages
  • Update the product design and ACP MVP planning documentation
  • Add Rust and frontend localization regression tests

Behavior

  • Validation occurs before admitting a Run, Attempt, or ACP prompt turn
  • Existing conversation history and composer input are preserved on failure
  • Agent doctor status remains unchanged
  • History reads, stop operations, and workspace listing remain available
  • The ACP adapter process-launch boundary is unchanged
  • No Windows error-code special cases or process-boundary fallback were added

Verification

  • Rust workspace admission tests: 5 passed
  • Frontend error localization tests: 9 passed
  • cargo fmt --all --check
  • TypeScript type checking
  • Vite production build
  • Browser verification of the conversation entry screen

Kevin4234 and others added 4 commits August 27, 2026 15:50
Run workspace metadata and directory access checks in the existing blocking pool before admitting runtime work. Preserve project-scoped command contracts and add thread-boundary and desktop API regression coverage.

Refs #108
Initialize synthetic provider provenance explicitly, import canonical test constants after the main merge, and synchronize workspace package versions in Cargo.lock.

Refs #108
@diodeme
diodeme merged commit 77f4f98 into main Aug 30, 2026
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants