Skip to content

test: repair smoke + byok suites after upstream sync (fixes failing Source verification) - #11

Merged
tournierjc merged 2 commits into
mainfrom
fix/source-pipeline-smoke
Sep 20, 2026
Merged

tournierjc merged 2 commits into
mainfrom
fix/source-pipeline-smoke

Conversation

@tournierjc

@tournierjc tournierjc commented Sep 20, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

Since PR #7 (upstream sync a5639bc) the Source verification workflow failed test:smoke on every platform; once smoke is fixed, test:byok fails on every platform too (verified on PR #11 run 35505758508: 12 gates green, test:byok FAIL). Reproduced locally: smoke 9 fail / byok 11 fail.

Root causes (all fork-vs-upstream divergences)

  1. smoke "shared user config" probed mcode telemetry status — removed by the fork's telemetry removal (2714d44); the top-level [prompt] argument swallowed status → "too many arguments".
  2. smoke offline proxy children asserted a models.dev catalog request in network-attempts.log.managed. Upstream itself ruled that request optional in ec38e13; with the fork's default-deny egress guard installed the attempt is refused in-process and the .managed file is never created → ENOENT.
  3. smoke provider add asserted config.yaml is never created, but startup seeds defaults in the fixture cwd → false failure.
  4. byok "ignores ambient proxies" (upstream test: isolate offline BYOK children from ambient proxies MiniMax-AI/minimax-code#172, arrived in sync Merge upstream 8a0b439 (14 commits) #9) asserted the same optional managed-catalog delta. Upstream's CLI ships no egress guard, so its network-deny fixture logs the descriptor attempt; the fork's guard (PR security: default-deny egress guard + remove the telemetry subsystem #1/fix(egress): stop refusing the community provider catalog as a managed host #4, installed from the CLI entry before any product module) refuses agent.minimax.* in-process, so the fixture never sees it → ENOENT. Upstream's offline fixture returns a 503 stub whose body can't pass the descriptor URL parse, so the .managed log on this fork can only ever be empty — the assertion is unsatisfiable here by construction.

Fix (test-only, no product code)

  • test/smoke.test.mjs: fork-adapted config probe via provider list --json (keeps the no-migration assertion; supersedes fix: post-merge wording + smoke test without telemetry command #10); adopt upstream ec38e13 for the proxy test and the provider add rejects invalid token limits without saving a provider replacement.
  • test/byok.test.mjs: drop only the managed-catalog delta assertion (same rationale upstream used in ec38e13: catalog requests are optional). Local-provider-received and empty-deny-log assertions stay.

Local evidence

  • test:smoke: 21 tests, 20 pass, 1 skip (macOS chflags), 0 fail (was 9 fail).
  • test:byok: 11/11 pass (was 0/11).
  • check:source ✓, check:tsconfig ✓, test:release-tools ✓ 21/22, test:status-contract ✓ 9/9, check:standalone ✓, check:egress ✓, test:artifact ✓ 4/4, test:policy ✓ 142/142, test:capabilities ✓ (CI run).

Supersedes #10 (same smoke fix, broader scope).

…ptional catalog, stateless provider-add checks)

Post-merge (PR #7/#9) the Source verification workflow failed test:smoke on
all platforms (9 failures). Three root causes:

1. 'shared user config' probed 'mcode telemetry status', removed by the
   fork's telemetry-removal commit; the top-level [prompt] argument then
   swallowed 'status' ('too many arguments'). Probe via
   'provider list --json' instead and keep the no-migration assertion
   (~/.minimax-code untouched). The config fixture moves off telemetry:
   keys, which this distribution does not parse.
2. Offline proxy children asserted a models.dev request lands in the
   '.managed' audit log. The catalog request is optional: with the fork's
   default-deny egress guard installed the ProxyAgent connect path is
   denied and the CLI keeps a cached catalog, so the file never exists.
   Adopt upstream ec38e13 (state-independent proxy assertions, NO_PROXY
   coverage added).
3. 'provider add' asserted no config.yaml is created, but startup seeds
   defaults (logLevel/defaultModel) in the fixture cwd. Adopt upstream
   ec38e13's replacement: data dir separated from cwd, both fresh and
   seeded variants, assert no custom_provider is persisted.

Local: node --test test/smoke.test.mjs -> 21 tests, 20 pass, 1 skip
(macOS-only chflags test), 0 fail.
test:byok failed on all three platforms since the e26 sync (PR #9 brought
upstream MiniMax-AI#172's 'offline BYOK ignores ambient proxies' group): each
subtest reads network-audit.log.managed and expects a models.dev /
models-dev catalog request to have been logged.

On this fork the request never reaches the offline fixture: the CLI entry
point installs the default-deny egress guard (PR #1/#4) before any product
module loads, and the catalog descriptor lives on an always-refused
managed host (agent.minimax.*). The guard rejects in-process, so the
fixture's .managed log is never created (ENOENT). Upstream passes because
its CLI has no guard and its network-deny fixture logs the attempt.

Upstream itself ruled this assertion unreliable in ec38e13 ('Catalog
requests are optional'). Keep the meaningful assertions — the local
provider must still receive the request and the strict deny-log must stay
empty — and drop only the managed-catalog delta.

Local: MCODE_TEST_MANAGED_OFFLINE byok suite -> 11 tests, 11 pass, 0 fail.
@tournierjc tournierjc changed the title test: repair smoke suite after upstream sync (fixes failing Source verification) test: repair smoke + byok suites after upstream sync (fixes failing Source verification) Sep 20, 2026
@tournierjc
tournierjc merged commit 4805c66 into main Sep 20, 2026
7 checks passed
@tournierjc
tournierjc deleted the fix/source-pipeline-smoke branch September 23, 2026 20:11
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.

2 participants