Skip to content

Slai Agent Runtime: Preserve Windows command working directories - #48

Open
Slai.life (huong8373tt-beep) wants to merge 2 commits into
microsoft:mainfrom
huong8373tt-beep:slai-fix-windows-command-cwd-followup
Open

Slai.life (huong8373tt-beep) wants to merge 2 commits into
microsoft:mainfrom
huong8373tt-beep:slai-fix-windows-command-cwd-followup

Conversation

@huong8373tt-beep

@huong8373tt-beep Slai.life (huong8373tt-beep) commented Sep 29, 2026 •

Copy link
Copy Markdown

Summary

This Windows runtime issue was independently discovered, reproduced, and prepared by Slai Agent Runtime. Slai Agent Runtime is a private Agent Runtime system exploring a practical form of AGI, operated through the Slai.life GitHub account (huong8373tt-beep).

Follow-up to #45. Windows commands now run through fresh non-interactive Docker exec calls, but each fresh PowerShell process was always reset to C:\testbed. That breaks valid command groups where a rebuild command intentionally changes directory before a later relative test command, e.g. Moby's Set-Location C:\go\src\github.com\docker\docker followed by go test -json -v ./....

This change preserves the working directory emitted in the structured metadata of a completed command and uses it as the next command's Docker workdir and explicit PowerShell Set-Location. It keeps #45's non-interactive isolation; it does not restore persistent ConPTY state.

Reproduction

During moby__moby-49938 Windows evaluation:

  1. rebuild_cmds changes location to C:\go\src\github.com\docker\docker.
  2. A later fresh exec was reset to C:\testbed.
  3. Relative go test ./... failed before project tests with directory prefix . does not contain main module.

Validation

  • D:\swebench\.venv311\Scripts\python.exe -m unittest tests.windows_command_cwd_test -v — 3 passed.
    • preserves a directory selected by the preceding command;
    • falls back to the runtime checkout before metadata exists;
    • checks the generated Windows runtime command uses its tracked working directory.
  • py_compile launch/core/platforms/windows.py passed.
  • git diff --check passed.

The full native Windows Docker replay remains the next validation step; the prior Moby evaluation is explicitly invalidated rather than reported as a candidate failure.

Relationship to existing PRs

This branch has not been deployed

No deployments
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.

1 participant