b26ed7c3e4
Working copies were stored as /data/working-copies/{repo_id}/{workspace_name}/,
so git clone was forced into a user-named directory. That meant the container
mount basename was the workspace name (e.g. main) instead of the repo name.
- Generate the workspace UUID before cloning and clone into
/data/working-copies/{workspace_id}/ so git creates {repo_name}/ naturally
- Set workspace.path to /data/working-copies/{workspace_id}/{repo_name}/
- Update _migrate_clone_into_workspace() to use the same layout
- _get_repository_mount_name() now prefers workspace.path basename and only
falls back to remote URL / repo.name for legacy repo-only instances
- Update unit tests to assert workspace path basename is used for mounts
Quality gates:
- pytest tests/unit: 219 passed
- ruff: clean on changed files
- mypy: clean on changed files
783 B
783 B
apps/api/src/services/tool (index)
dir: apps/api/src/services/tool
role
Provides infrastructure orchestration for isolated tool instances, managing their complete lifecycle from provisioning to teardown.
parent
index: apps/api/src/services/.pi-map.index.md map: apps/api/src/services/.pi-map.md
children
- apps/api/src/services/tool/.ruff_cache index: apps/api/src/services/tool/.ruff_cache/.pi-map.index.md map: apps/api/src/services/tool/.ruff_cache/.pi-map.md
files
- instance_service.py
links
index: apps/api/src/services/tool/.pi-map.index.md map: apps/api/src/services/tool/.pi-map.md
workflows
- change tool behavior read: instance_service.py
- explore tool subdirectories index: apps/api/src/services/tool/.ruff_cache/.pi-map.index.md