Summary
After update_environment_directory switches a thread to another directory, the composer footer continues to show the original project name. The thread uses the new directory correctly, but the UI makes it appear that the switch failed.
Reproduction
- Start a thread in project
project-a.
- Call
update_environment_directory with /path/to/project-b.
- Send another message so the provider starts in the new environment.
- Check the workspace label in the composer footer.
Current behavior
The environment is updated correctly:
environment.path is /path/to/project-b.
- The branch and working-tree summary come from
project-b.
- The thread still has the
project-a project ID.
- The footer shows only
project-a.
This creates conflicting UI signals. The branch and diff belong to project-b, while the adjacent folder label says project-a.
Expected behavior
When the active environment path differs from the project root, the composer footer should show the active workspace directory:
The full environment path should be available in a tooltip:
The UI should update as soon as the thread environment changes. It should not require a page reload.
Summary
After
update_environment_directoryswitches a thread to another directory, the composer footer continues to show the original project name. The thread uses the new directory correctly, but the UI makes it appear that the switch failed.Reproduction
project-a.update_environment_directorywith/path/to/project-b.Current behavior
The environment is updated correctly:
environment.pathis/path/to/project-b.project-b.project-aproject ID.project-a.This creates conflicting UI signals. The branch and diff belong to
project-b, while the adjacent folder label saysproject-a.Expected behavior
When the active environment path differs from the project root, the composer footer should show the active workspace directory:
The full environment path should be available in a tooltip:
The UI should update as soon as the thread environment changes. It should not require a page reload.