Skip to content

test: make 14-git-collab worker/project setup deterministic#1007

Open
RerankerGuo wants to merge 2 commits into
agentscope-ai:mainfrom
RerankerGuo:fix/test-14-deterministic-setup
Open

test: make 14-git-collab worker/project setup deterministic#1007
RerankerGuo wants to merge 2 commits into
agentscope-ai:mainfrom
RerankerGuo:fix/test-14-deterministic-setup

Conversation

@RerankerGuo

@RerankerGuo RerankerGuo commented Jul 8, 2026

Copy link
Copy Markdown

Mirrors the test-06 deterministic-bob-setup pattern from #985 for tests/test-14-git-collab.sh. Addresses the SHARD_B copaw/hermes failure observed on #984 (run 28926397804, job 85816940745).

Root cause

In the test-14 failure on #984, Manager successfully created the three workers (alice, bob, charlie) and the project room, then hung for 30 minutes on a tool-guard approval prompt while trying to update meta.json status from planning to active (the jq | mv | cat pipeline in YOLO-mode Step 1d.1 of the project-management skill). The test timeout (1800s) then expired waiting for the completion message that never came.

Fix

Pre-create the workers + project room in the test runner before sending the task to Manager:

  1. Workers — loop hiclaw apply worker --name alice|bob|charlie ... (same CLI Manager would call). wait_for_worker_container per worker to confirm provisioning. No LLM in the loop.
  2. Project roomcreate-project.sh --id proj-collab-test-${TEST_RUN_ID} --workers alice,bob,charlie. Same script Manager would call, so the Matrix room + directory tree + admin/worker invites + Manager groupAllowFrom update all happen deterministically.
  3. meta.json — jq-set status=active and confirmed_at=now, then sync to MinIO via mc mirror. This makes Manager's YOLO-mode Step 1d.1 a no-op — no tool-guard prompt is ever raised.
  4. Task description sent to Manager — now starts with explicit "workers and project room are pre-configured — DO NOT call create-project.sh, DO NOT update meta.json" preamble, followed by the unchanged 4-phase coordination logic.
  5. Cleanup — extended to remove the pre-created project directory and MinIO prefix in addition to the bare git repo.

What still gets tested

The test still exercises Manager's full 4-phase coordination logic in isolation — the phase assignment table, the sequential waiting for phase reports, the exact branch-name / file-path / report-name invariants are all unchanged. What changed is that the test runner owns the setup steps (worker creation, project room creation, meta.json activation) so Manager's tool-guard control loop is no longer in the test critical path.

Files

  • tests/test-14-git-collab.sh — pre-create setup + simplified task description + extended cleanup (+57 / -12 lines)
  • changelog/current.md — entry under Bug Fixes

Companion PRs

Refs: #984

Pre-create the 3 workers (alice, bob, charlie) via hiclaw apply worker and
the shared project via create-project.sh + immediate meta.json activation
+ MinIO sync, before sending the 4-phase task to Manager. Manager now
focuses on phase coordination only — the worker + project setup steps that
previously stalled on Manager's tool-guard approval prompt (jq | mv | cat
on meta.json) are now in the test runner and never enter the LLM control
loop.

Mirrors the fix in agentscope-ai#985 for test-06-multi-worker.sh (bob creation flake).
Both fixes isolate LLM-driven coordination from infrastructure setup so
the test measures coordination quality, not LLM timing.

Fixes the SHARD_B copaw/hermes test-14 failure seen on agentscope-ai#984 (run 28926397804,
job 85816940745), where Manager hung for 30 minutes on a tool-guard approval
prompt while trying to update meta.json status.

Refs: agentscope-ai#984
@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

❌ Integration Tests Failed (llm-interaction-2 / mgr=copaw / wk=hermes)

Commit: e8eaa88
Workflow run: #1520

Test Results
No test output captured.
Debug Log (tail)
No debug logs available.

📦 Download full debug logs & test artifacts

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

❌ Integration Tests Failed (llm-interaction-2 / mgr=openclaw / wk=openclaw)

Commit: e8eaa88
Workflow run: #1520

Test Results
No test output captured.
Debug Log (tail)
No debug logs available.

📦 Download full debug logs & test artifacts

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

❌ Integration Tests Failed (llm-interaction / mgr=copaw / wk=copaw)

Commit: e8eaa88
Workflow run: #1520

Test Results
No test output captured.
Debug Log (tail)
No debug logs available.

📦 Download full debug logs & test artifacts

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

📊 CI Metrics Report

Summary

Metric Current Baseline Change
LLM Calls 85 81 +4 ↑ +4.9%
Input Tokens 2473744 2803871 -330127 ↓ -11.8%
Output Tokens 14824 16791 -1967 ↓ -11.7%
Total Tokens 2488568 2820662 -332094 ↓ -11.8%

By Role

Role Metric Current Baseline Change
🧠 Manager LLM Calls 71 68 +3 ↑ +4.4%
Input Tokens 2131763 2502214 -370451 ↓ -14.8%
Output Tokens 12112 13725 -1613 ↓ -11.8%
Total Tokens 2143875 2515939 -372064 ↓ -14.8%
🔧 Workers LLM Calls 14 13 +1 ↑ +7.7%
Input Tokens 341981 301657 +40324 ↑ +13.4%
Output Tokens 2712 3066 -354 ↓ -11.5%
Total Tokens 344693 304723 +39970 ↑ +13.1%

Per-Test Breakdown

Test Mgr Calls Wkr Calls Δ Calls Mgr In Wkr In Mgr Out Wkr Out Δ Tokens Trend
02-create-worker 4 0 -8 ↓ -66.7% 102875 0 485 0 -255262 ↓ -71.2% ✅ improved
03-assign-task 10 7 +2 ↑ +13.3% 250804 168506 1446 1100 -51800 ↓ -10.9% ⚠️ regressed
04-human-intervene 17 0 +4 ↑ +30.8% 368149 0 2010 0 -62839 ↓ -14.5% ⚠️ regressed
05-heartbeat 6 0 -1 ↓ -14.3% 169175 0 1145 0 -104932 ↓ -38.1% ✅ improved
06-multi-worker 34 7 +7 ↑ +20.6% 1240760 173475 7026 1612 +142739 ↑ +11.2% ⚠️ regressed

Trends

2 test(s) improved (fewer LLM calls)
⚠️ 3 test(s) regressed (more LLM calls)


Generated by HiClaw CI on 2026-07-09 06:34:28 UTC


📦 Download debug logs & test artifacts

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

❌ Integration Tests Failed (llm-interaction-2 / mgr=copaw / wk=copaw)

Commit: e8eaa88
Workflow run: #1520

Test Results
No test output captured.
Debug Log (tail)
No debug logs available.

📦 Download full debug logs & test artifacts

v1 over-prescribed by pre-creating the project room and instructing Manager
not to call create-project.sh. That broke Manager's natural workflow —
it lost its entry point for the rest of the coordination and ended up
writing ad-hoc Matrix HTTP scripts (run 28948704338). copaw/hermes made
Manager do 136 LLM calls + alice 54 calls + bob/charlie 0 (phases 2-4
never started).

v2 only pre-creates the 3 workers (the actual flake source on SHARD_A).
Manager still walks through create-project.sh + YOLO Step 1d (meta.json
active transition) + 4-phase coordination as the workflow intends — this
test measures that flow, not LLM timing on worker creation.

Refs: agentscope-ai#984
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