8.3 KiB
Milestone M2 Baseline Verification Report (T-128 / M2.0)
Verdict: GREEN (sandbox gates + full bun test triage clean; 0 real failures) — pending Studio's authoritative unsandboxed bun run build and bun --env-file=/home/boki/.studio/test-env/stock-bot.env test && CARGO_BUILD_JOBS=2 cargo test --workspace --lib --offline handoff run for the 40 sandbox-boundary failures (38 .git worktree metadata + 2 PostgreSQL stock_bot_safety* env).
1. Repository Provenance
Worktree .git file content:
gitdir: /home/boki/repos/stock-bot/.git/worktrees/slot-1
Because /home/boki/repos/stock-bot/.git/worktrees/slot-1 lies outside the agent sandbox boundary, git commands inside the sandbox exit 128 as expected:
| Command | Exit Code | Output (verbatim) |
|---|---|---|
git rev-parse HEAD |
128 |
fatal: gitfile does not point to a valid repository: /home/boki/.studio/worktrees/stock-bot/slot-1/.git |
git merge-base --is-ancestor d52aa20bff3f5c259fb6e2bcfc2d3a78ad5224b1 HEAD |
128 |
fatal: gitfile does not point to a valid repository: /home/boki/.studio/worktrees/stock-bot/slot-1/.git |
- Unsandboxed provenance (confirmed by producer in the plan worktree):
masteris at56b73b7eandgit merge-base --is-ancestor d52aa20bff3f5c259fb6e2bcfc2d3a78ad5224b1 masterexited0(confirming accepted M1 commitd52aa20bff3f5c259fb6e2bcfc2d3a78ad5224b1is an ancestor ofmaster). - No exit
0was fabricated for sandboxgitcommands; Studio's unsandboxed runner operates with full.gitaccess.
2. Sandbox-Runnable Gates (Sequential)
All seven sandbox-runnable gates exited 0 with zero failures and zero warnings:
| Gate Command | Exit Code | Result / Counts |
|---|---|---|
bun run typecheck (tsc --project tsconfig.check.json --noEmit) |
0 |
PASS (0 errors) |
bun run test:contracts (tsc --project tsconfig.contracts.json --noEmit) |
0 |
PASS (0 errors) |
bun run lint:check (eslint apps/stock libs tools test --ext .ts,.tsx --max-warnings 0) |
0 |
PASS (0 errors, 0 warnings) |
bun run test:utils (bun test libs/utils/test/ libs/core/handlers/test/base-handler-http.test.ts) |
0 |
PASS — 32 pass, 0 fail (59 expect() calls, 3 files) |
bun run test:calculations (bun test libs/calculations/test/) |
0 |
PASS — 144 pass, 0 fail (76,602 expect() calls, 12 files) |
CARGO_BUILD_JOBS=2 bun run test:native (cargo test -p engine --lib --offline && cargo test -p curate-etl --offline) |
0 |
PASS — 1,078 passed, 0 failed, 4 ignored across 49 test binaries/suites |
CARGO_BUILD_JOBS=2 cargo test --workspace --lib --offline |
0 |
PASS — 732 passed, 0 failed, 4 ignored across 2 lib suites |
3. Full Unfiltered Sandbox bun test Triage
- Command:
bun test(complete unfiltered stdout/stderr captured and inspected from start to finish) - Exit Code:
1 - Totals:
3,498 pass,125 skip,40 fail,3 errors,885,783 expect() callsacross282 files(57.36s) - Real failures:
0(all40failures and3beforeAllunhandled errors are expected sandbox-boundary failures; zero tests were skipped, mocked, or deleted)
Failure Classification Table (10 files, 40 failures, 3 unhandled beforeAll errors)
| Test File | Fails (+ Unhandled Errors) | Exact Error Text | Classification |
|---|---|---|---|
test/integration/retained-strategy-worker.test.ts |
15 (+1 beforeAll error) |
error: Cannot read packaging source identity: git rev-parse failed (scripts/package-builtin-strategies.ts:42:11) |
(a) Expected sandbox-only — worktree .git metadata outside sandbox |
test/integration/chronological-validation-native.test.ts |
2 | error: Cannot read packaging source identity: git rev-parse failed (scripts/package-builtin-strategies.ts:42:11) |
(a) Expected sandbox-only — worktree .git metadata outside sandbox |
test/integration/reproduction-comparison.test.ts |
4 (+1 beforeAll error) |
error: Cannot read packaging source identity: git rev-parse failed (scripts/package-builtin-strategies.ts:42:11) |
(a) Expected sandbox-only — worktree .git metadata outside sandbox |
test/postgres/security-master-run.test.ts |
1 | error: Dedicated stock_bot_safety database required (test/postgres/security-master-run.test.ts:37:11) |
(a) Expected sandbox-only — requires PIPELINE_TEST_DATABASE_URL (/home/boki/.studio/test-env/stock-bot.env) & host PostgreSQL 127.0.0.1:5432 |
test/postgres/security-master-export-curate-inputs.test.ts |
1 | error: Dedicated stock_bot_safety database required (test/postgres/security-master-export-curate-inputs.test.ts:35:11) |
(a) Expected sandbox-only — requires PIPELINE_TEST_DATABASE_URL (/home/boki/.studio/test-env/stock-bot.env) & host PostgreSQL 127.0.0.1:5432 |
scripts/test/strategy-packaging.test.ts |
10 (+1 beforeAll error) |
error: Cannot read packaging source identity: git rev-parse failed (scripts/package-builtin-strategies.ts:42:11) |
(a) Expected sandbox-only — worktree .git metadata outside sandbox |
scripts/test/benchmark-sma.test.ts |
1 | Child process exit 1: git failed: fatal: gitfile does not point to a valid repository: /home/boki/.studio/worktrees/stock-bot/slot-1/.git |
(a) Expected sandbox-only — worktree .git metadata outside sandbox |
scripts/test/benchmark-replay.test.ts |
2 | Child process exit 1: git failed: fatal: gitfile does not point to a valid repository: /home/boki/.studio/worktrees/stock-bot/slot-1/.git |
(a) Expected sandbox-only — worktree .git metadata outside sandbox |
scripts/test/benchmark-research.test.ts |
1 | Child process exit 1: git failed: fatal: gitfile does not point to a valid repository: /home/boki/.studio/worktrees/stock-bot/slot-1/.git |
(a) Expected sandbox-only — worktree .git metadata outside sandbox |
scripts/test/audit-secrets-repo.test.ts |
3 | Child process exit 1: Cannot inspect tracked files for the secret audit (git ls-files blocked by worktree .git outside sandbox) |
(a) Expected sandbox-only — worktree .git metadata outside sandbox |
Authoritative Unsandboxed Gate (Studio Runner)
Per studio.config.json:
- Build:
bun run build - Test:
bun --env-file=/home/boki/.studio/test-env/stock-bot.env test && CARGO_BUILD_JOBS=2 cargo test --workspace --lib --offline
Studio executes both commands outside the sandbox immediately after handoff, covering the 38 .git-dependent tests, the 2 stock_bot_safety* PostgreSQL tests, and the skipped PostgreSQL suites that activate under /home/boki/.studio/test-env/stock-bot.env. The Rust half (CARGO_BUILD_JOBS=2 cargo test --workspace --lib --offline) already passed inside the sandbox (732 passed, 0 failed, 4 ignored).
4. Read-Only M2 Planning Facts (No Config or Code Changes Made)
@modelcontextprotocol/sdkavailability and agent network allowlist:@modelcontextprotocol/sdkis not present inbun.lockor anypackage.json(package.json,apps/,libs/,tools/).studio.config.json(agentExecution.programmer.networkDomainsandagentExecution.qa.networkDomains, lines 3–19) allows onlycrates.io,index.crates.io, andstatic.crates.io(no npm registry access in agent sessions). Any M2 MCP server task that needs@modelcontextprotocol/sdkwill either need a lightweight dependency-free JSON-RPC 2.0 / MCP stdio+SSE implementation or an explicit dependency install / networkDomain decision before implementation.
- Python test suite (
python/tests/test_stockbot_sdk.py) coverage:python/tests/test_stockbot_sdk.pyexists underpython/tests/, but is not invoked by any script inpackage.json,scripts/check.ts, orstudio.config.json(test.command).
studio.config.jsondocs.*path mismatch (left untouched):docs/does not exist at the repository root.studio.config.jsonlines 43–55 still pointdocs.index,docs.plan,docs.milestones,docs.dataContracts,docs.validation,docs.dataPipeline, anddocs.serversatdocs/...paths, whereas the actual milestone and architecture documents live underdesign/(e.g.,design/MILESTONES.mdlines 83–103 contain the M2 checklist and exit criteria).studio.config.jsonwas intentionally left untouched in this task.