Repository navigation
fix(showcase): warn on unregistered services, unbind runner registry - #8287
Conversation
…way services Creating a Railway service before SERVICES lists it is the normal order for adding a Showcase integration, but the image gate failed it as untracked. That turned main red and skipped staging redeploys (run 42607303530). Generalise the starter-* carveout: a service with a staging or prod instance that is not in SERVICES now prints "WARN unregistered Railway service" and passes, along with its docs-preview copies. Permanent IDs under a new name, registered names with another ID, services with no staging/prod instance, recorded disposable environments, disposable claims and invalid evidence still fail. No lifecycle policy change. Refs PNI-785 Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Important Review skippedIgnore keyword(s) in the title. ⛔ Ignored keywords: 4
Please check the settings in the CodeRabbit UI or the
|
|
🚅 Deployed to the CopilotKit-pr-8287 environment in showcase 52 services not affected by this PR
|
Production Digest-Pinning AuditAll 43 services digest-pinned. Run 2026-11-09 23:36:31 PST — 0 finding(s). |
…registry The staging rich-thread runner is parked. Every new Showcase service changes the lifecycle policy hash, and while readers are connected to the runner's registry each one needs a reviewed reader transition plus a runner deploy. Stop passing SHOWCASE_DISPOSABLE_RUN_RECORDS_FILE/_TOKEN and SHOWCASE_REGISTRY_CONSUMER to the image gate (showcase_build, eval-webhook build) and the ordinary promote steps (showcase_promote, docs_promote), so they run in static-fleet mode. Static mode grants no disposable exemptions, so it is stricter, never looser. The opt-in validate_registry_only step stays bound for checking the registry before reconnecting. A workflow test enforces this, and railway-lifecycle.md documents the disconnected state, the staging-harness step and how to reconnect. Refs PNI-786 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Address CodeRabbit review on the registry disconnect. Without registry evidence the image gate cannot see recorded runs, so the starter-* carveout would accept an unregistered starter inside a disposable-runner environment and skip its image check. Fetch environment names and grant no exception in any `rich-` environment, connected or not. Also stop the lifecycle doc banner from implying the staging harness is already disconnected. Refs PNI-786 Co-Authored-By: Claude Opus 5.5 <[email protected]>
…8290) ## Why The staging rich-thread runner (the PNI-596 test rig) is parked. In 9 dispatches it has never passed, and nothing depends on it. Today, every new Showcase service changes the disposable-lifecycle policy hash. While the Showcase checks read the runner's registry, each new service needs a hand-reviewed reader transition plus a one-off runner deploy. That is what #8242 is currently stuck on. Disconnecting the readers removes that coupling. Tracked in PNI-786 (parent PNI-783). ## What changes - **Normal reader steps no longer get the registry binding.** That binding is `SHOWCASE_DISPOSABLE_RUN_RECORDS_FILE` / `_TOKEN` and `SHOWCASE_REGISTRY_CONSUMER`. The affected steps are: - the image gate in `showcase_build.yml` and `showcase_eval-webhook_build.yml`; - the promote steps in `showcase_promote.yml` and `docs_promote.yml`. These readers now run in static-fleet mode, the documented "neither configured" path. The both-or-neither guards that are no longer needed are removed. - **The opt-in `validate_registry_only` dispatch step stays connected**, so the registry can still be checked before reconnecting. The repo variable and secret stay configured for it; nothing is deleted. - **New test in `registry-validation-workflows.test.ts`:** in these four workflows, only that validation step may reference the binding. Against main's workflows the test fails 4/4, so reconnecting a normal reader has to be a deliberate, reviewed change. - **Image gate: no exception in runner environments** (from CodeRabbit review). Without registry evidence the gate can't see recorded runs. The `starter-*` exception would then accept an unregistered starter inside a runner environment and skip its image check. `verify-railway-image-refs.ts` now also fetches environment names and grants no exception in any `rich-…` environment, whether or not the registry is connected. 4 new tests. Run offline against a 2026-11-10 snapshot of the Railway project, it reports only main's existing `showcase-openai-agents-python` failure, which #8287 fixes. This overlaps #8287 in the same function: whichever PR merges second gets rebased, and the same rule applies to #8287's broader exception. - **`showcase/scripts/railway-lifecycle.md`** gets a "Registry disconnected" section and a banner. The section covers the precondition, the staging-harness step and how to reconnect. **Safety.** Static mode grants no disposable exemptions. A leftover runner service would therefore show up as unknown and fail, so this is stricter, never looser. Precondition, checked read-only at 2026-11-10 06:52Z: all three `rich-*` Railway environments have zero service instances. ## Not in this PR: staging harness (manual, after merge) The staging `harness` Railway service reads the same three variables from its own Railway config, so a PR can't change it. They'll be removed together and the harness redeployed, step by step, after this merges. With the registry configured, a failed or mismatched read aborts all staging discovery. So the harness must be disconnected before #8242 changes the policy hash, unless #8242 carries its reader transition. ## Merge order - Independent of #8287 (the unregistered-service warning). - Once this merges and the harness is disconnected, #8242 no longer needs its `4ded…` → `5c3b…` reader transition. ## Verification - `registry-validation-workflows.test.ts` passes 9/9. The new cases fail against main's workflows. - The full `@copilotkit/showcase-scripts:test` suite passes through Nx (102 files, 3141 tests). - actionlint finds nothing new: the same 15 findings as main in these four files. - oxlint and oxfmt are clean. 🤖 Generated with [Claude Code](https://claude.com/claude-code) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> <!-- coderabbit-ai-generated:v1 --> ## Summary by CodeRabbit * **Updates** * Showcase image verification and promotion workflows now use static-fleet mode, disconnected from disposable-runner registry evidence. * In named Railway runner environments, unregistered starter services now fail image verification, even when a tolerated staging instance exists. The starter-service exception remains available outside runner environments. * **Documentation** * Lifecycle guidance explains the disconnection, staging-harness status, runner-environment limitations, the zero-service precondition, and steps for reconnecting. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
The registry disconnect now lands inside this PR, so a squash merge leaves no separate commit to revert. Spell out which workflow entries to restore. Refs PNI-786 Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Size Change: 0 B Total Size: 2.47 MB ℹ️ View Unchanged
|
Refs PNI-786 Co-Authored-By: Claude Opus 5.5 <[email protected]>
mme
left a comment
There was a problem hiding this comment.
Thanks Mark, looks good. The exception stays narrow: only services with a staging or prod instance get a warning, while mismatched IDs, runner environments and image problems still fail. Approving.
…t#8242) ## What does this PR do? Adds the **OpenAI Agents SDK (Python)** showcase package, `showcase/integrations/openai-agents-python`. It runs on the AG-UI adapter `ag-ui-openai-agents` 0.1.0 from PyPI, released today from ag-ui-protocol/ag-ui#2210. - **Layout.** A FastAPI agent server has one AG-UI endpoint per demo at `POST /<name>`. Each demo is a plain module-level `Agent` wrapped in the adapter's `OpenAIAgentsAgent`. The Next runtime routes map each agent name to its path. Inbound `x-*` mock and diagnostic headers are copied onto every model call, and `x-aimock-context` is fixed to the slug. - **Coverage.** 39 features are declared, and all 42 D6 cells are green. `cli-start` is the only feature not supported, because there is no CLI starter yet. - **What the adapter does.** It turns approval pauses into AG-UI interrupts, resumes statelessly from the `resume` entries, gives tools the run's state through `shared_state()`, keeps reasoning in `MESSAGES_SNAPSHOT`, and passes the page's tools to the model as client tools. - **App-level shims.** Two subclasses of `OpenAIAgentsAgent` cover what the adapter leaves to the app: - `SchedulerAgent` (gen-ui-interrupt, interrupt-headless) hands the picked time from the resume payload to the paused `schedule_meeting` call. - `DocumentStreamingAgent` (shared-state-streaming) streams the `write_document` argument into state while the model writes it. - **Model.** Like the other OpenAI-backed integrations since a358fa0, it defaults to `gpt-6-luna`. The chat agents, the sub-agents and the A2UI render call run with reasoning off (`chat_settings()` in `_common.py`), and the reasoning demos keep low effort with summaries. - **Deployment.** Staging only, and the package stays `deployed: false` until a prod instance exists. The Railway service `showcase-openai-agents-python` exists in staging, configured like `showcase-ag2` with `OPENAI_BASE_URL` on the env-local aimock. A later commit wires it into `showcase_build.yml` and `railway-envs.ts`, so a push to main builds the image and redeploys it. Commits are split by area: agent server, demo app, e2e and D6 fixtures, registration, CI, docs. Later commits add what the first CI run caught (the config allowlist entry, the compatibility mapping and two count tests), the switch to GPT-6 Luna, the Railway staging wiring and the lifecycle policy bridge. ## Known gaps - **CopilotKit pins.** The package is pinned to CopilotKit 1.76.0 through the canonical pins, like `google-antigravity`. On that version, 4 declarative-gen-ui Playwright tests fail because they need the `data-message-role` attribute from a newer react-core. - **CVDIAG.** The backend emitter works. D6 test ids aren't UUIDv7, so backend rows don't join probe rows. That's the same for every Python integration. ## Related PRs and Issues - Adapter: ag-ui-protocol/ag-ui#2210 (merged, `ag-ui-openai-agents` 0.1.0 on PyPI) - Dojo published lane on PyPI: ag-ui-protocol/ag-ui#3329 - Docs pages for this package (stacked on this PR): CopilotKit#8245 ## Test plan - [x] `bin/showcase test openai-agents-python --d6 --isolate --rebuild` on the rebased branch: 43/43 status records green (42 cells plus the slug aggregate); all 149 aimock calls matched a fixture - [x] Package Playwright specs, run the way the on-demand E2E job runs them (native aimock with the CI fixture set and `AIMOCK_STRICT_TURN_INDEX=1`, uvicorn on the PyPI adapter, `next start`): 188 passed, 2 skipped, 4 failed. All 4 failures are the declarative-gen-ui `data-message-role` tests described above. - [x] `showcase/scripts` vitest after merging main (with CopilotKit#8287) and adding the lifecycle bridge: 3214/3214. Putting the old `d3a7…` validator back turns 12 tests red. oxfmt, oxlint and harness `tsc` are clean. - [x] `validate-manifests`, `validate-routes` - [x] shell-docs vitest: 586/586 (the declarative-hashbrown count moves from 15 to 16 for the new package) - [x] shell-dashboard `npm test`: 1866 passed (the compatibility mapping gains `openai-agents`, with the adapter excluded) - [x] `.github/scripts/check-config-allowlist.sh`: the package's `next.config.ts` is on the allowlist - [x] `pytest tests/python`: 20 passed against `ag-ui-openai-agents==0.1.0` from PyPI - [x] After the Luna switch: D6 is green again (43/43, 149/149 aimock calls matched). Captured request bodies show `gpt-6-luna` with `reasoning: {effort: "none"}` for chat agents, sub-agents and the A2UI call, and `effort: "low", summary: "auto"` for the reasoning demo. aimock's journal doesn't record `reasoning`, so this was checked against a stub transport. - [x] Railway staging wiring: `verify-railway-image-refs.ts` against live Railway with no records file: 87 env-scoped instances verified. `emit-railway-envs-json --check` and `sync-promote-service-options --check` are up to date. - [ ] CI build check on this PR ## Checklist - [x] I have read the [Contribution Guide](https://github.com/copilotkit/copilotkit/blob/master/CONTRIBUTING.md) - [x] If the PR changes or adds functionality, I have updated the relevant documentation - [x] If the PR contains a breaking change, the title has `!` and the description has a `BREAKING CHANGE:` line (not breaking) - [x] "Allow edits by maintainers" is checked
Why
Adding a Showcase service normally means creating the Railway service first and adding it to
SERVICESafterwards. The image gate fails that in-between state as "untracked". On 2026-11-09,showcase-openai-agents-pythonwas created in staging before #8242 registered it. That turned main red (run 42607303530), which skipped staging redeploys and blocked other work.Separately, every new Showcase service changes the disposable-lifecycle policy hash. While the Showcase checks read the parked rich-thread runner's registry, each new service needs a hand-reviewed reader transition plus a one-off runner deploy, and that is what #8242 is stuck on. The runner (the PNI-596 test rig) has 0 successful runs in 9 dispatches, and nothing depends on it.
What changes
1. Unregistered staging/prod services warn instead of failing (
verify-railway-image-refs.ts, PNI-785)SERVICESentry prints⚠ WARN unregistered Railway service "<name>" (<id>) in <env>plus a GitHub::warning::. It passes with no image check.CopilotKit-pr-*) environments copy staging.showcase/RAILWAY.mdnow says registering a service is safe in either order.2. Workflow readers disconnected from the runner registry (PNI-786, from #8290)
showcase_build.ymlandshowcase_eval-webhook_build.yml, and the normal promote steps inshowcase_promote.ymlanddocs_promote.yml, no longer receive these settings:SHOWCASE_DISPOSABLE_RUN_RECORDS_FILESHOWCASE_DISPOSABLE_RUN_RECORDS_TOKENSHOWCASE_REGISTRY_CONSUMERvalidate_registry_onlydispatch step stays connected. The repo variable and secret stay configured for it; nothing is deleted.registry-validation-workflows.test.tsenforces that only that step uses the binding.showcase/scripts/railway-lifecycle.mdgets a "Registry disconnected" section: the precondition, the staging-harness step, and how to reconnect.3. No exception inside runner environments (from CodeRabbit review on #8290)
starter-*one nor the new one) in anyrich-…environment, whether or not the registry is connected.No lifecycle-policy or hash change.
Staging harness: already disconnected (outside this PR)
The staging
harnessRailway service read the same three variables from its own Railway settings. On 2026-11-10 at 07:32Z, they were removed together and the harness was redeployed with the same image. Smoke at 07:35Z: 22/24 passing, which matches the baseline, withdiscoveryFailed=falseand no lifecycle lines. The pre-change values and restore source are in PNI-786.So once this merges, no Showcase reader reads the runner registry. #8242 still needs its
4ded…→5c3b…transition, but only because its own lifecycle tests pin the committed policy hash.Precondition, checked read-only at 2026-11-10 07:30Z: all three
rich-*environments have zero service instances.Verification
@copilotkit/showcase-scripts:testpasses through Nx (102 files, 3154 tests).untracked: showcase-openai-agents-python, matching CI;tscerrors are inshell-dashboard/scripts/compatibility-audit/xml.ts, and they are also on main.🤖 Generated with Claude Code