fix(e2e): include MINIMAX_API_KEY in CREATE payload for byok MiniMax slugs (7c657011) #2649

Merged
devops-engineer merged 1 commits from fix/7c657011-byok-staging-create-payload into main 2026-06-12 16:25:52 +00:00
Member

Closes delegation 7c657011.

Controlplane now validates BYOK model credentials at create-time (POST /workspaces) and returns MISSING_BYOK_CREDENTIAL if the vendor key is absent from the create payload for a BYOK model slug (MiniMax-M2.x). test_staging_full_saas.sh was stripping MINIMAX_API_KEY into DEFERRED_SECRETS_JSON and only writing it after the byok opt-in, which ran AFTER the create — so the create itself failed.

Repro on main SHA 15872306:

  • continuous-synth-e2e run 352760/job 476956 (MiniMax-M2.7)
  • staging-smoke run 352743/job 476924 (MiniMax-M2.7)
    Both failed with MISSING_BYOK_CREDENTIAL at POST /workspaces.

Fix: remove MINIMAX_API_KEY from BYOK_STRIP_KEYS. For the MiniMax arm this keeps the key in CREATE_SECRETS_JSON (so create-time validation passes) and leaves DEFERRED_SECRETS_JSON="" (so the deferred-write loop is a clean no-op). Matches the recent controlplane change "atomic byok create — payload vendor key satisfies the gate AND the vendor-key guard" (commit 871a156e, #2640).

Non-MiniMax arms (anthropic, google, openai-hermes, platform) are unchanged: they never set MINIMAX_API_KEY in SECRETS_JSON, so removing it from the strip list is a no-op for them. MINIMAX_CN_API_KEY (separate slug path, not the failing arm) remains strip-listed.

Verify: re-run continuous-synth-e2e + staging-smoke. Both should now reach the byok-routing assertion (job 476956 / 476924).

Minimal change, single-file, no controlplane change needed.

Closes delegation 7c657011. Controlplane now validates BYOK model credentials at create-time (POST /workspaces) and returns MISSING_BYOK_CREDENTIAL if the vendor key is absent from the create payload for a BYOK model slug (MiniMax-M2.x). test_staging_full_saas.sh was stripping MINIMAX_API_KEY into DEFERRED_SECRETS_JSON and only writing it after the byok opt-in, which ran AFTER the create — so the create itself failed. Repro on main SHA 15872306: - continuous-synth-e2e run 352760/job 476956 (MiniMax-M2.7) - staging-smoke run 352743/job 476924 (MiniMax-M2.7) Both failed with MISSING_BYOK_CREDENTIAL at POST /workspaces. Fix: remove MINIMAX_API_KEY from BYOK_STRIP_KEYS. For the MiniMax arm this keeps the key in CREATE_SECRETS_JSON (so create-time validation passes) and leaves DEFERRED_SECRETS_JSON="" (so the deferred-write loop is a clean no-op). Matches the recent controlplane change "atomic byok create — payload vendor key satisfies the gate AND the vendor-key guard" (commit 871a156e, #2640). Non-MiniMax arms (anthropic, google, openai-hermes, platform) are unchanged: they never set MINIMAX_API_KEY in SECRETS_JSON, so removing it from the strip list is a no-op for them. MINIMAX_CN_API_KEY (separate slug path, not the failing arm) remains strip-listed. Verify: re-run continuous-synth-e2e + staging-smoke. Both should now reach the byok-routing assertion (job 476956 / 476924). Minimal change, single-file, no controlplane change needed.
agent-dev-b added 1 commit 2026-06-12 16:20:46 +00:00
fix(e2e): include MINIMAX_API_KEY in CREATE payload for byok MiniMax slugs (7c657011)
CI / Python Lint & Test (pull_request) Successful in 3s
Block internal-flavored paths / Block forbidden paths (pull_request) Successful in 3s
E2E API Smoke Test / detect-changes (pull_request) Successful in 5s
Handlers Postgres Integration / detect-changes (pull_request) Successful in 3s
sop-checklist / review-refire (pull_request_target) Has been skipped
gate-check-v3 / gate-check (pull_request_target) Successful in 4s
Lint forbidden tenant-env keys / Scan for repo-host token write into tenant workspace surface (pull_request) Successful in 6s
Lint forbidden tenant-env keys / Scan workspace_secrets writers for forbidden env keys (pull_request) Successful in 6s
Handlers Postgres Integration / Handlers Postgres Integration (pull_request) Successful in 2s
Secret scan / Scan diff for credential-shaped strings (pull_request) Successful in 7s
reserved-path-review / reserved-path-review (pull_request_target) Successful in 7s
sop-checklist / all-items-acked (pull_request) acked: 0/7 — missing: comprehensive-testing, local-postgres-e2e, staging-smoke, +4 — body-unfilled: comprehensive-testing, local-postgres-e2
sop-checklist / na-declarations (pull_request) N/A: (none)
sop-checklist / all-items-acked (pull_request_target) Successful in 10s
CI / Detect changes (pull_request) Successful in 17s
E2E Chat / detect-changes (pull_request) Successful in 16s
E2E Staging Canvas (Playwright) / detect-changes (pull_request) Successful in 16s
CI / Platform (Go) (pull_request) Successful in 2s
CI / Canvas (Next.js) (pull_request) Successful in 3s
lint-required-no-paths / lint-required-no-paths (pull_request) Successful in 17s
E2E Chat / E2E Chat (pull_request) Successful in 3s
CI / Canvas Deploy Status (pull_request) Successful in 2s
E2E Staging Canvas (Playwright) / Canvas tabs E2E (pull_request) Successful in 3s
Local Provision Lifecycle E2E / Local Provision Lifecycle E2E (stub) (pull_request) Successful in 1m4s
Local Provision Lifecycle E2E / Local Provision Lifecycle E2E (real image + MiniMax LLM, advisory) (pull_request) Failing after 18s
CI / Shellcheck (E2E scripts) (pull_request) Successful in 1m23s
CI / all-required (pull_request) Successful in 4s
E2E API Smoke Test / E2E API Smoke Test (pull_request) Successful in 2m28s
reserved-path-review / reserved-path-review (pull_request_review) Successful in 8s
qa-review / approved (pull_request_target) Approved via pull_request_review trigger
security-review / approved (pull_request_target) Approved via pull_request_review trigger
security-review / approved (pull_request_review) Successful in 9s
qa-review / approved (pull_request_review) Successful in 10s
audit-force-merge / audit (pull_request_target) Successful in 8s
E2E Staging SaaS (full lifecycle) / pr-validate (pull_request) Waiting to run
E2E Staging SaaS (full lifecycle) / E2E Staging SaaS (pull_request) Waiting to run
E2E Staging SaaS (full lifecycle) / E2E Staging Platform Boot (pull_request) Waiting to run
E2E Staging SaaS (full lifecycle) / E2E Staging Concierge user_tasks (pull_request) Waiting to run
E2E Staging SaaS (full lifecycle) / E2E Staging Concierge Creates Workspace (pull_request) Waiting to run
E2E Staging SaaS (full lifecycle) / E2E Staging Concierge (compile+skip) (pull_request) Waiting to run
E2E Staging SaaS (full lifecycle) / E2E Staging Concierge Platform Agent (pull_request) Waiting to run
b5009993f9
Controlplane now validates BYOK model credentials at create-time
(POST /workspaces) and returns MISSING_BYOK_CREDENTIAL if the vendor
key is absent from the create payload for a BYOK model slug
(MiniMax-M2.x). test_staging_full_saas.sh was stripping MINIMAX_API_KEY
into DEFERRED_SECRETS_JSON and only writing it after the byok opt-in,
which ran AFTER the create — so the create itself failed.

Repro on main SHA 15872306:
  - continuous-synth-e2e run 352760/job 476956 (MiniMax-M2.7)
  - staging-smoke    run 352743/job 476924 (MiniMax-M2.7)
Both failed with MISSING_BYOK_CREDENTIAL at POST /workspaces.

Fix: remove MINIMAX_API_KEY from BYOK_STRIP_KEYS. For the MiniMax arm
this keeps the key in CREATE_SECRETS_JSON (so create-time validation
passes) and leaves DEFERRED_SECRETS_JSON='{}' (so the deferred-write
loop is a clean no-op). Matches the recent controlplane change
'atomic byok create — payload vendor key satisfies the gate AND the
vendor-key guard' (commit 871a156e, #2640).

Non-MiniMax arms (anthropic, google, openai-hermes, platform) are
unchanged: they never set MINIMAX_API_KEY in SECRETS_JSON, so removing
it from the strip list is a no-op for them. MINIMAX_CN_API_KEY
(separate slug path, not the failing arm) remains strip-listed.

Verify: re-run continuous-synth-e2e + staging-smoke. Both should now
reach the byok-routing assertion (job 476956 / 476924).
agent-reviewer-cr2 approved these changes 2026-06-12 16:25:32 +00:00
agent-reviewer-cr2 left a comment
Member

APPROVED: 5-axis review complete on head b5009993f9. Correctness: the change is scoped to the BYOK split list in tests/e2e/test_staging_full_saas.sh and only removes MINIMAX_API_KEY from BYOK_STRIP_KEYS, letting MiniMax BYOK creates carry the vendor key in CREATE_SECRETS_JSON; non-MiniMax arms and MINIMAX_CN_API_KEY remain untouched. Robustness/tests: CI / all-required is green and the script comment documents the create-time gate regression. Security: no new secret exposure beyond preserving the existing MiniMax key in the create payload for the BYOK path that now requires it. Performance: no impact. Maintainability: the exception is documented at the exact split point.

APPROVED: 5-axis review complete on head b5009993f9163d0db3462c5a13b4ce7b7e60dc49. Correctness: the change is scoped to the BYOK split list in `tests/e2e/test_staging_full_saas.sh` and only removes `MINIMAX_API_KEY` from `BYOK_STRIP_KEYS`, letting MiniMax BYOK creates carry the vendor key in `CREATE_SECRETS_JSON`; non-MiniMax arms and `MINIMAX_CN_API_KEY` remain untouched. Robustness/tests: `CI / all-required` is green and the script comment documents the create-time gate regression. Security: no new secret exposure beyond preserving the existing MiniMax key in the create payload for the BYOK path that now requires it. Performance: no impact. Maintainability: the exception is documented at the exact split point.
devops-engineer merged commit 6dea7c46b3 into main 2026-06-12 16:25:52 +00:00
Sign in to join this conversation.
No Reviewers
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: molecule-ai/molecule-core#2649