-
Notifications
You must be signed in to change notification settings - Fork 0
Implementation Plan: Fix xdist Isolation — Hardcoded /dev/shm and /tmp Paths (groupB) #563
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -26,7 +26,7 @@ def factory(runner=None): | |
|
|
||
|
|
||
| @pytest.mark.anyio | ||
| async def test_run_headless_core_no_add_dir_when_empty(make_ctx): | ||
| async def test_run_headless_core_no_add_dir_when_empty(make_ctx, tmp_path): | ||
| """T-OVR-012: run_headless_core with empty add_dirs emits no --add-dir flags.""" | ||
| from autoskillit.execution.headless import run_headless_core | ||
| from tests.conftest import _make_result | ||
|
|
@@ -38,7 +38,9 @@ async def mock_runner(cmd, **kwargs): | |
| return _make_result() | ||
|
|
||
| ctx = make_ctx(runner=mock_runner) | ||
| await run_headless_core("/autoskillit:investigate foo", "/tmp/proj", ctx, add_dirs=()) | ||
| proj = tmp_path / "proj" | ||
|
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [info] cohesion: Creates |
||
| proj.mkdir() | ||
| await run_headless_core("/autoskillit:investigate foo", str(proj), ctx, add_dirs=()) | ||
| assert "--add-dir" not in captured_cmd | ||
|
|
||
|
|
||
|
|
@@ -64,9 +66,11 @@ async def mock_runner(cmd, **kwargs): | |
| return _make_result() | ||
|
|
||
| ctx = make_ctx(runner=mock_runner) | ||
| proj = tmp_path / "proj" | ||
| proj.mkdir() | ||
| await run_headless_core( | ||
| "/autoskillit:investigate foo", | ||
| "/tmp/proj", | ||
| str(proj), | ||
| ctx, | ||
| add_dirs=[dir_a, dir_b], | ||
| ) | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -20,6 +20,9 @@ | |
| def test_resolve_ephemeral_root_returns_writable_dir( | ||
| tmp_path: Path, monkeypatch: pytest.MonkeyPatch | ||
| ) -> None: | ||
| import autoskillit.workspace.session_skills as ss | ||
|
|
||
| monkeypatch.setattr(ss, "_CANDIDATE_ROOTS", [tmp_path]) | ||
|
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [warning] cohesion:
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Investigated — this is intentional. resolve_ephemeral_root() at session_skills.py:54 appends 'autoskillit-sessions' to each candidate root, so tmp_path as a candidate root means all I/O lands in tmp_path/autoskillit-sessions/ — correctly isolated. test_resolve_ephemeral_root_fallback (line 37) also passes tmp_path directly without issue. The _CANDIDATE_ROOTS pattern (base dirs) and the cwd argument (project dirs) are different abstractions; surface consistency across them would be misleading. |
||
| root = resolve_ephemeral_root() | ||
| assert root.exists() | ||
| assert root.is_dir() | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[info] cohesion: Passes
str(tmp_path)directly ascwdwithout creating a subdirectory (e.g.tmp_path / 'proj'), while tests intest_headless_add_dirs.pycreate an explicitprojsubdirectory. The cwd construction pattern differs across the diff.