Skip to content

test(delegation): isolate and retire fixture-owned Effect runtimes - #5535

Open
songoow wants to merge 1 commit into
loopx-project:mainfrom
songoow:codex/delegation-fixture-runtime-isolation
Open

songoow wants to merge 1 commit into
loopx-project:mainfrom
songoow:codex/delegation-fixture-runtime-isolation

Conversation

@songoow

@songoow songoow commented Oct 3, 2026

Copy link
Copy Markdown
Collaborator

Goal And Delivered Outcome

  • Outcome basis: test-infrastructure repair ported from closed feat(delegation): stop delegated members with acknowledged, settled receipts #5308.
  • Goal/source and gap: the delegation service fixture changed TMPDIR/TEMP/TMP for its children but left Python's cached tempfile.tempdir untouched, so a warmed parent could route to a different Effect runtime than its native CLI children. It also left each case's private runtime alive until the five-minute idle shutdown, accumulating servers across the suite, including failed setups.
  • Observable before → after: before, the extended isolation test failed on the old fixture. After, it passes. A neighboring runtime survives teardown.

Author Declaration

  • Written by: model_agent — Claude Fable 5.1 (Anthropic), operated by @songoow.

Implemented against

Criterion (spec clause) Disposition Symbol / path Test or command
N/A N/A tests/test_local_delegation.py uv run --extra test python -m pytest -q tests/test_local_delegation.py -k isolates_cached_and_child_runtime_routes
  • Self-check before submission: ran the isolation test on main (fails), applied the patch (passes), ran the whole delegation test file (green).

Scope And Continuation

Validation

  • Tested revision: 759349919
  • Run state: finished
  • Input classes: File and SQLite delegation service fixtures
Check kind Result Public-safe evidence / limitation
smoke passed tests/test_local_delegation.py::test_delegation_fixture_isolates_cached_and_child_runtime_routes on the fixed fixture (was failing on main).
suite passed Whole tests/test_local_delegation.py (~32 cases).
  • Coverage and gaps: test-infrastructure only, no product runtime change.

See validation disclosure guidance.

Frontend / Visual Evidence

  • UI impact: none

Type of Change

  • Tests

LoopX Area

  • Control plane (goals, todos, quota, scheduler, registry, runtime)

Technical Direction

Shared-authority RFC fixture impact

  • N/A: test-infrastructure only; no fixture, provider, projection or runtime routing change in production code.

Boundary Checklist

  • Neither the diff nor this PR body/comments/attachments disclose private state, credentials, raw traces or verifier output, internal links, or local machine paths.
  • I did not duplicate maintainer-owned benchmark work unless a maintainer split out a public issue for it.
  • I kept the change scoped to the linked issue/task.
  • I completed the visual evidence section for UI changes, or marked UI impact none.
  • Every commit includes a DCO Signed-off-by trailer (git commit -s).

🤖 Generated with Claude Code

The delegation service fixture changed TMPDIR/TEMP/TMP for its children
but left Python's cached tempfile.tempdir untouched, so a warmed parent
could route to a different Effect runtime than its native CLI children.
It also left each case's private runtime alive until the five-minute idle
shutdown, accumulating servers across the suite, including failed setups.

Reuse the canonical isolate_sqlite_runtime helper for both routes and
register a finalizer that shuts the fixture's own runtime down through
the existing restart API. The extended isolation test fails on the old
fixture and passes afterward; a neighboring runtime survives teardown.

Ported from the closed loopx-project#5308 (13f4c93, bdbd440) as a standalone
test-infrastructure change. Production code is unchanged.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Signed-off-by: song <liusongstep@gmail.com>
@songoow
songoow requested a review from huangruiteng as a code owner October 3, 2026 14:58

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