Skip to content

feat(showcase): support --isolate=<N> CLI form as sugar over SHOWCASE_ISO_SLOT - #5547

Merged
jpr5 merged 2 commits into
mainfrom
fix/showcase-isolate-equals-n
Jun 18, 2026
Merged

jpr5 merged 2 commits into
mainfrom
fix/showcase-isolate-equals-n

Conversation

@jpr5

@jpr5 jpr5 commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

Summary

Follow-up to #5543. Adds --isolate=<N> CLI form so users don't need to set SHOWCASE_ISO_SLOT=<N> as an env var prefix.

Before

SHOWCASE_ISO_SLOT=9 bin/showcase test agno --d5 --isolate

After (both forms work)

bin/showcase test agno --d5 --isolate=9
# OR
SHOWCASE_ISO_SLOT=9 bin/showcase test agno --d5 --isolate

Implementation

~10 lines in showcase/scripts/cli/cmd-test.sh arg parser: a new --isolate=* case sets use_isolate=true and exports SHOWCASE_ISO_SLOT=<N>. The existing picker (_claim_isolate_slot in _common.sh) handles all validation, slot-0 rejection, port-probe, liveness, etc. — no logic duplication.

Help text in cmd-test.sh and the existing SHOWCASE_ISO_SLOT references in showcase/TESTING.md now show both forms as equivalent.

Tests

Four new bats tests in showcase/scripts/__tests__/isolate.bats:

  • --isolate=<N> arg form exports SHOWCASE_ISO_SLOT and pins the slot through the picker — replays the parser branch, verifies env export + picker pinning.
  • --isolate=0 arg form drives the picker's reserved-slot rejection — proves --isolate=0 flows through the same slot 0 is reserved die as the env-var form.
  • --isolate=99 arg form drives the picker's out-of-range rejection — proves --isolate=99 flows through the same exceeds ISOLATE_MAX_SLOT=45 die as the env-var form.
  • cmd-test.sh --isolate=<N> actually wires the arg through to SHOWCASE_ISO_SLOT — drift guard that sources the REAL cmd-test.sh, stubs apply_isolation, and snapshots SHOWCASE_ISO_SLOT to catch any future regression of the parser branch.

All 58 bats tests in isolate.bats pass locally (54 pre-existing + 4 new).

Docs

showcase/TESTING.md items 8 and 9 updated to show both forms. Repo-wide grep confirmed TESTING.md is the only doc that references SHOWCASE_ISO_SLOT.

Test plan

  • bats showcase/scripts/__tests__/isolate.bats → 58/58 green
  • --isolate=9 → SHOWCASE_ISO_SLOT exported, slot 9 claimed
  • --isolate=0 → picker dies "slot 0 is reserved"
  • --isolate=99 → picker dies "exceeds ISOLATE_MAX_SLOT=45"
  • shellcheck showcase/scripts/cli/cmd-test.sh → no new warnings (only the pre-existing SC2034 on CMD_TEST_DESC, consumed by dispatcher parallel arrays)
  • oxfmt --check showcase/ → clean

jpr5 added 2 commits June 18, 2026 10:38
…_ISO_SLOT

Adds a sugar form of the --isolate flag that pins the isolation slot
directly from the command line:

    bin/showcase test agno --d5 --isolate=9
    # equivalent to:
    SHOWCASE_ISO_SLOT=9 bin/showcase test agno --d5 --isolate

The arg parser splits --isolate=<N> into setting use_isolate=true plus
exporting SHOWCASE_ISO_SLOT=<N>; the existing picker
(_claim_isolate_slot in _common.sh) handles all validation — positive
integer, slot 0 reserved, 1<=N<=ISOLATE_MAX_SLOT, port probe, liveness.
No validation logic is duplicated.

Tests:
- replays the parser branch and verifies SHOWCASE_ISO_SLOT export +
  picker pinning
- drives the picker's reserved-slot (N=0) and out-of-range (N=99)
  rejections through the arg form to pin the parser->env->picker wiring
- drift guard: sources the REAL cmd-test.sh, stubs apply_isolation, and
  snapshots SHOWCASE_ISO_SLOT to catch any future regression of the
  parser branch

Help text and TESTING.md updated in a follow-up commit.
Items 8 and 9 now show both the SHOWCASE_ISO_SLOT=<N> env-var form and
the --isolate=<N> CLI sugar as equivalent ways to pin the isolation
slot. The env-var form remains valid — the CLI form is a convenience,
not a replacement.

A repo-wide grep confirmed showcase/TESTING.md is the only doc that
references SHOWCASE_ISO_SLOT, so no other docs need updating.
@vercel

vercel Bot commented Jun 18, 2026 •

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
chat-with-your-data Ready Ready Preview, Comment Jun 18, 2026 5:42pm
docs Ready Ready Preview, Comment Jun 18, 2026 5:42pm
form-filling Ready Ready Preview, Comment Jun 18, 2026 5:42pm
research-canvas Ready Ready Preview, Comment Jun 18, 2026 5:42pm
travel Ready Ready Preview, Comment Jun 18, 2026 5:42pm

Request Review

@github-actions

Copy link
Copy Markdown
Contributor

📣 Social Copy Generator

Generate social media copies (Twitter/X, LinkedIn, Blog Post) for this PR using Claude.

  • Generate social media copies

@github-actions

Copy link
Copy Markdown
Contributor

Production Digest-Pinning Audit

12 of 41 service(s) not digest-pinned.

Service Source.image Status
starter-adk ghcr.io/copilotkit/starter-adk:latest mutable-tag
starter-agno ghcr.io/copilotkit/starter-agno:latest mutable-tag
starter-crewai-crews ghcr.io/copilotkit/starter-crewai-crews:latest mutable-tag
starter-langgraph-fastapi ghcr.io/copilotkit/starter-langgraph-fastapi:latest mutable-tag
starter-langgraph-js ghcr.io/copilotkit/starter-langgraph-js:latest mutable-tag
starter-langgraph-python ghcr.io/copilotkit/starter-langgraph-python:latest mutable-tag
starter-llamaindex ghcr.io/copilotkit/starter-llamaindex:latest mutable-tag
starter-mastra ghcr.io/copilotkit/starter-mastra:latest mutable-tag
starter-ms-agent-framework-dotnet ghcr.io/copilotkit/starter-ms-agent-framework-dotnet:latest mutable-tag
starter-ms-agent-framework-python ghcr.io/copilotkit/starter-ms-agent-framework-python:latest mutable-tag
starter-pydantic-ai ghcr.io/copilotkit/starter-pydantic-ai:latest mutable-tag
starter-strands-python ghcr.io/copilotkit/starter-strands-python:latest mutable-tag

Run 2026-06-18 10:40:12 PDT — 12 finding(s).

This branch was successfully deployed

5 active deployments
Preview – research-canvas — 0e7e3116 Deployed Jun 18, 2026 by vercel[bot]
Preview – travel — 0e7e3116 Deployed Jun 18, 2026 by vercel[bot]
Preview – form-filling — 0e7e3116 Deployed Jun 18, 2026 by vercel[bot]
Preview – docs — 0e7e3116 Deployed Jun 18, 2026 by vercel[bot]
Preview – chat-with-your-data — 0e7e3116 Deployed Jun 18, 2026 by vercel[bot]
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