Commit Graph

313 Commits

Author SHA1 Message Date
Jordan Ritter f97bf875d9 fix: include review items in docs-sync Slack notification (#3940)
## Summary
- The docs-sync warning notification was sending "see workflow run for
details" with no actionable information
- Now reads `review-items.txt` and includes the file list directly in
the Slack message
- Recipients can see which files need attention without digging through
CI logs

## Test plan
- [ ] Trigger docs-sync with a file that has showcase-local
modifications (exit code 3 path)
- [ ] Verify Slack notification includes the file list in a code block
- [ ] Verify auto-push-only path (exit code 0) still does NOT send the
warning notification
2026-04-15 16:18:46 -07:00
Jordan Ritter ccbc19a436 fix: include review items in docs-sync Slack notification
The warning notification for files needing manual review was sending
'see workflow run for details' with no actionable information.

- Read review-items.txt and include file list in the Slack message
- Use jq for proper JSON escaping (handles newlines, quotes, special chars)
- Guard against missing review-items.txt with fallback and ::warning::
- Review-needed notification fires independently of push/merge outcome
2026-04-15 16:13:27 -07:00
Jordan Ritter 1fd938ac35 feat: add starter deployed smoke test CI workflow
New workflow running starter health/agent/chat tests against Railway:
- Triggers: 6h cron, after showcase deploy, manual dispatch
- Alerts on schedule + workflow_run failures (Slack + GitHub issue)
- Issue dedup by title match, continue-on-error on Slack
- Proper working-directory for npm ci and Playwright install
2026-04-15 15:17:13 -07:00
Jordan Ritter 580a3e9214 fix: langgraph-python starter agent — permissions, imports, and tools.py naming collision
Root causes (verified locally with docker build + run):
1. PermissionError: non-root user can't write .langgraph_api dir — fix: chown -R app:app /app
2. ImportError: relative imports fail in langgraph_cli context — fix: absolute imports
3. ValueError: tools.py and tools/ directory collision — fix: rename to tool_wrappers.py

Tested: docker run returns {"status":"ok","agent":"ok"}
2026-04-14 17:06:02 -07:00
Jordan Ritter e3e8edcd42 fix: remove invalid secrets reference in deploy workflow step conditions 2026-04-14 15:41:52 -07:00
Jordan Ritter 10edf630f6 fix: clean Slack alert formatting across showcase workflows (#3914)
## Summary

- **drift-detection**: Split inline payload into `jq`-built file +
`payload-file-path`; sanitize playwright output (strip ANSI, head -3,
cap 200 chars)
- **starter-smoke**: Replace `toJSON(format(...))` double-encoding with
`jq` payload builder
- **showcase_deploy**: Replace 300-char inline ternary with readable
shell conditional + `jq`

All three workflows now use the same pattern: build a sanitized JSON
file with `jq -n`, then reference it via `payload-file-path`. This
eliminates raw `%0A` in Slack messages, unformatted stack traces, and
double-encoded JSON.

## Test plan

- [ ] Trigger `showcase_drift-detection.yml` manually — verify Slack
alert formats correctly on failure
- [ ] Trigger `starter-smoke.yml` manually — verify Slack alert on a
known-failing starter
- [ ] Trigger `showcase_deploy.yml` with `service: shell` — verify
deploy notification renders cleanly
- [ ] Confirm no `%0A` or raw escape sequences appear in any Slack
message
2026-04-14 15:38:07 -07:00
Jordan Ritter 8a013f9a08 fix: remove test-integration-tmp from starter-smoke matrix (lost in #3899 merge) 2026-04-14 15:37:21 -07:00
Jordan Ritter 6e66ea626b fix: clean Slack alert formatting across showcase workflows
Use jq to build JSON payloads safely and payload-file-path to avoid
inline multiline content. Limits error context to 3 lines, strips ANSI
codes, and caps field length at 200 chars.

- drift-detection: split payload build from post, sanitize playwright output
- starter-smoke: replace toJSON(format(...)) double-encoding with jq
- showcase_deploy: replace 300-char inline ternary with readable shell conditional
2026-04-14 15:33:41 -07:00
Jordan Ritter 44dec7c72e fix: harden deploy pipeline — independent concurrency, post-deploy health checks 2026-04-14 14:44:44 -07:00
Jordan Ritter 569f85246c fix: format showcase_deploy.yml 2026-04-14 14:13:59 -07:00
Jordan Ritter 72a7f16ca5 fix: remove shared_frontend from Dockerfiles and test-integration-tmp from CI 2026-04-14 13:43:36 -07:00
Jordan Ritter c25c1ca291 fix: remove shared_frontend COPY from demo package Dockerfiles (deleted in #3896) 2026-04-14 13:27:05 -07:00
Jordan Ritter 6f27637380 feat: add on-demand aimock e2e test workflow with PR comment trigger 2026-04-14 13:01:44 -07:00
Jordan Ritter 5ac07d4d9b feat: CI, shell, and aimock integration for showcase starters
CI:
- Add 17 starter services to showcase deploy workflow with Railway IDs
- Add drift detection workflow (triggers on starters, packages, scripts, shared)
- Remove shared_frontend copy step for starter builds

Shell:
- Update clone command to npx degit with clipboard fallback
- Update starter content bundler for full component tree + .java support
- Add clone_command to manifest schema and registry types

Aimock:
- Expand feature-parity.json from 18 to 37 fixture rules
- Add docker-compose.packages.yml for CI aimock sidecar (strict mode)
- Add run-e2e-with-aimock.sh convenience script
2026-04-14 12:52:52 -07:00
Jordan Ritter 7b31011e24 fix: revert serviceInstanceUpdate — CI token lacks permission
The RAILWAY_TOKEN in GitHub secrets can't call serviceInstanceUpdate
(403 Forbidden). Services are now all configured to pull :latest, so
serviceInstanceRedeploy will pull the latest image automatically.
2026-04-13 23:22:54 -07:00
Jordan Ritter 02b85fd809 fix: update Railway image source before redeploy
Railway was pinned to old SHA tags — serviceInstanceRedeploy just
restarts the existing image. Now the deploy step calls
serviceInstanceUpdate to set the image to the exact SHA just pushed,
then triggers the redeploy. Also re-enables Docker cache.
2026-04-13 23:02:47 -07:00
Jordan Ritter 7bd2af08fa fix: disable Docker cache to force rebuild with new code
The GHA Docker layer cache was serving stale builds — renderer adapter
code wasn't in the deployed images despite successful builds. Disabling
cache-from forces a full rebuild. Will re-enable after cache is fresh.
2026-04-13 22:51:37 -07:00
Jordan Ritter 5aed8ee088 fix: resolve 4 remaining showcase deploy failures
- Remove test-integration-tmp from workflow (package was deleted)
- starter-langgraph-python: disable Turbopack for Next.js build
  (serverExternalPackages incompatible with Turbopack)
- starter-crewai-crews: pin crewai-tools~=0.47.1 to avoid version
  conflict with crewai==0.130.0
- shell-dojolike: add missing zod dependency (required by shared
  frontend modules)
2026-04-13 21:37:03 -07:00
Jordan Ritter d551f099b6 fix: remove duplicate test_integration_tmp key in deploy workflow
The paths-filter YAML had test_integration_tmp defined twice (lines 71
and 90), causing a "duplicated mapping key" parse error that blocked all
deploy runs.
2026-04-13 21:24:53 -07:00
Jordan Ritter e55139c62e fix: cp -r trailing slash creates double-nested dirs in CI deploy
The CI workflow's shared module copy step used trailing slashes on both
source and destination (cp -r src/ dest/src/), which on Linux copies the
*contents* into an already-created dest/src/ — resulting in
shared_frontend/src/src/ instead of shared_frontend/src/. Same issue
for shared_typescript/tools/.

Root cause confirmed via diagnostic instrumentation: index.ts existed at
the wrong depth, leaving the webpack alias target empty.

Fix: mkdir only the parent, cp without trailing slashes so the directory
itself is placed correctly. Also removes the diagnostic debug line from
pydantic-ai Dockerfile.
2026-04-13 21:22:37 -07:00
Jordan Ritter ae3d871542 feat: showcase feature parity: shared tools, Sales Dashboard, A2UI across all 17 integrations (#3873)
## Summary
- Create `@copilotkit/showcase-shared` — shared frontend package with
React hooks, components, A2UI catalog, and SalesDashboard
- Create shared Python + TypeScript tool implementations (get_weather,
query_data, manage_sales_todos, search_flights, schedule_meeting,
generate_a2ui)
- Upgrade all 17 showcase integrations to full feature parity with the
langgraph-python starter
- Docker builds verified locally for all 17 packages
- Comprehensive test coverage: 165 unit tests, 68 React component tests,
130+ Playwright e2e files

## Commits
1. `feat:` shared packages — frontend, Python tools, TypeScript tools,
unit tests, React component tests, aimock fixtures
2. `feat:` all 17 package upgrades — tools, demo pages, cross-cutting
fixes, Playwright e2e tests
3. `feat:` Docker + CI — tsconfig paths resolution, shared module
copying, spring-ai base image fix
4. `chore:` pnpm lockfile update

## Code review
5 rounds of fresh unbiased MSAL (1 dedicated agent per package, zero
prior context). Round 5: **20/20 packages PASS with 0 findings.** Test
quality audit: all criticality-7+ gaps fixed.

## Docker builds (all 17 verified locally)
```
langgraph-python         langgraph-typescript  
langgraph-fastapi        mastra               
pydantic-ai              claude-sdk-typescript 
crewai-crews             spring-ai            
google-adk               ms-agent-dotnet      
agno                     claude-sdk-python     
ag2                      langroid             
strands                  ms-agent-python      
llamaindex           
```

## Test coverage
- Python unit: 54 tests (tools + parity + framework wrappers)
- TypeScript unit: 43 tests
- React component: 68 tests (7 suites)
- Playwright e2e: 130+ files, per-package UI adaptation
- Aimock: 18 deterministic fixtures (ready for Docker-compose wiring)

## Known gaps (follow-up PR)
- Feature set varies: langgraph-python/fastapi have 9 demos, rest have 4
- gen-ui-tool-based: Chart/Haiku/Sales Pipeline variants across packages
- HITL: MeetingTimePicker vs step-selector variants
- Node 22 upgrade across all Dockerfiles + CI

## Test plan
- [x] `python3 -m pytest showcase/shared/python/tests/ -v` (54 passed)
- [x] `npx vitest run --config
showcase/shared/typescript/vitest.config.ts` (43 passed)
- [x] `npx vitest run --config
showcase/shared/frontend/vitest.config.ts` (68 passed)
- [x] Docker build all 17 packages locally
- [ ] Deploy to Railway and run smoke tests

🤖 Generated with [Claude Code](https://claude.com/claude-code)
2026-04-13 20:17:54 -07:00
Jordan Ritter 810f8a4f4d feat: Docker + CI — Node 22, shared module copying
- Node 20 → 22 in all Dockerfiles + CI workflows
- CI copies shared_python, shared_frontend/src, shared_typescript/tools
- tsconfig paths for @copilotkit/showcase-shared
- .gitignore for CI artifacts
2026-04-13 19:57:59 -07:00
Jordan Ritter c070403014 feat: Docker and CI support for shared showcase modules
- CI copies shared_python, shared_frontend/src, shared_typescript/tools into
  each package's build context before Docker build
- 12 Python Dockerfiles: COPY shared_python, ENV PYTHONPATH
- All Dockerfiles: npm install --legacy-peer-deps + tsconfig paths for
  @copilotkit/showcase-shared (no npm dependency needed)
- spring-ai: unpinned eclipse-temurin:17 base images
- Aimock: 18 deterministic fixtures for all demo scenarios
2026-04-13 17:39:05 -07:00
Jordan Ritter fbb9d01584 fix: upgrade docs sync token action to v2, add failure context
The v1 action uses SubtleCrypto.importKey() which fails with 'Invalid keyData'
on certain PEM key formats. v2 handles this more robustly.

Also adds step-level failure info to the Slack notification so we know
WHICH step failed instead of just 'workflow failed'.
2026-04-13 15:03:54 -07:00
Jordan Ritter 60f3b899df fix: version drift Slack alert links directly to GitHub issue 2026-04-13 09:31:56 -07:00
Jordan Ritter ed065725a4 fix: address CR findings — deploy needs, rebuild loop resilience, merge-failure alert, loop prevention, drift failure alert 2026-04-12 14:57:18 -07:00
Jordan Ritter c0fb38959a fix: add Slack alerts across all showcase workflows, fix silent failures and loop risk 2026-04-12 14:50:21 -07:00
Jordan Ritter 7a5ebbf1e3 fix: docs sync auto-merges via devops bot (bypasses branch protection) 2026-04-12 14:02:00 -07:00
Jordan Ritter 4f4541b711 fix: docs sync uses PRs instead of direct push (branch protection) 2026-04-12 13:33:13 -07:00
Jordan Ritter 63948957e0 fix: docs sync commit messages need conventional prefix + skip hooks 2026-04-12 13:23:06 -07:00
Jordan Ritter 4bf09a1eb0 fix: docs sync Slack notifications fire even when PR step fails 2026-04-12 13:14:50 -07:00
Jordan Ritter c3bb61c10e fix: docs sync PR step — stage and commit review items before creating PR 2026-04-12 13:04:11 -07:00
Jordan Ritter c1877db0d5 fix: set human_input_mode=NEVER on ag2 showcase agent (#3777)
## Summary

Two fixes:

### 1. AG2 showcase agent blocks on human feedback
The `ConversableAgent` defaults to `human_input_mode="TERMINATE"`, which
prompts for user feedback when the conversation terminates. In the AG-UI
streaming context via `AGUIStream`, this blocks with:
> "Please give feedback to the sender. Press enter to skip and use
auto-reply, or type 'exit' to stop the conversation:"

This was broken from day one (showcase deployed April 8, first L4 test
ran April 9 and failed). The ag2 image was never rebuilt since — the
unpinned `ag2>=0.9.0` dep resolved to 0.11.5 at build time.

Fix: set `human_input_mode="NEVER"`.

### 2. Showcase E2E Slack alerts lack detail
The Slack notification only said "Showcase E2E suite failed" with a
link. Now captures playwright output and includes failed test names +
error messages:

```
 Showcase E2E suite failed
View run

  1) [L4: tools] ag2 renders tool results @tools
    Error: ag2 response doesn't contain weather info: "Please give feedback..."
```

Test names now carry their level prefix (`[L1: health]`, `[L2: agent]`,
`[L3: chat]`, `[L4: tools]`) so you can tell what broke from the Slack
message alone.

🤖 Generated with [Claude Code](https://claude.com/claude-code)
2026-04-12 12:27:47 -07:00
Jordan Ritter 734d552e37 fix: include failure details in Showcase E2E Slack alerts
The Slack notification for E2E failures only said "Showcase E2E suite
failed" with a link. Now captures playwright output, extracts failed
test names and error messages, and includes them in the Slack message
as a code block so the team can see what broke without clicking through.
2026-04-11 18:21:24 -07:00
Jordan Ritter 69d46e0b00 fix: Fix drift detection: run only integration-smoke tests (#3776)
## Summary

The drift detection workflow runs `npx playwright test --grep
"@health|@agent|@chat"` which matches BOTH `integration-smoke.spec.ts`
(deployed Railway backends) and `starter-smoke.spec.ts` (Docker-built
starters). The starter-smoke tests try to connect to `localhost:3000`
which doesn't exist in CI, causing all runs to fail.

Fix: scope to `npx playwright test integration-smoke --grep ...` so only
the showcase integration tests run.

## Test plan

- [x] Verified locally: 13 integration-smoke tests pass, 0 starter-smoke
tests included

🤖 Generated with [Claude Code](https://claude.com/claude-code)
2026-04-11 08:30:03 -07:00
Jordan Ritter 466361f8a1 fix: scope drift detection to integration-smoke only (exclude starter-smoke) 2026-04-11 08:27:43 -07:00
Tyler Slaton beff7a859e test: add bumpPackages tests, wire release tests into CI
- Add tests for bumpPackages: verifies workspace:* protocol is
  preserved and exact version deps are updated
- Add vitest config for scripts/release/
- Add release script test step to test_unit.yml so these run on
  every PR and push to main
2026-04-10 23:08:12 -07:00
Tyler Slaton 2a880fb09c ci: add scope dropdown (monorepo, cli, angular) to release workflows
Each release scope has its own packages, version source, and
independent version track:
- monorepo: 12 core @copilotkit/* packages (shared version)
- cli: copilotkit CLI (independent version)
- angular: @copilotkitnext/angular (independent version)

Branch pattern is now release/publish/<scope>/v<version> and git
tags use <scope>/v<version> for non-monorepo scopes.
2026-04-10 23:04:48 -07:00
Tyler Slaton dacc21ea35 ci: restrict release workflows to main branch only
Add if: github.ref == 'refs/heads/main' to both release / create-pr
and release / pre jobs. Running from a feature branch will skip
immediately.
2026-04-10 22:51:27 -07:00
Tyler Slaton 5b84c16b55 ci: fix Node 20 compat, rename workflows, add unit tests
- Replace import.meta.dirname (Node 21.2+) with fileURLToPath
  workaround for Node 20 compatibility
- Rename workflows to release / pre, release / publish, release /
  create-pr so they group together in the Actions UI
- Fix semver regex to allow hyphens in prerelease identifiers
- Add unit tests for parseSemver, computeNextStableVersion,
  computePrereleaseVersion
2026-04-10 22:43:53 -07:00
Tyler Slaton 387784c7bd ci: add bespoke stateless release system
Replace changesets with a simple, stateless release system:

Stable release (PR-gated):
  Actions → "create release PR" → pick patch/minor/major → CI runs →
  merge → publishes to npm, creates git tag + GitHub Release

Prerelease (ad-hoc):
  Actions → "publish / prerelease" → publishes current version with
  -canary.<suffix|timestamp> to npm under "canary" tag

Key features:
- All 12 core @copilotkit/* packages share a single version
- AI-generated release notes via Anthropic API
- Notion draft for team editing before merge
- Notion link commented on the release PR
- Guards: concurrent release PR check, version > npm check, clean
  semver check, canary-only prerelease tag
- release/publish/v* branch pattern (hard to accidentally match)
- TypeScript throughout (tsx runner)
- release.config.json with versionedTogether/versionedIndependently
2026-04-10 22:20:43 -07:00
Tyler Slaton ab74b737f0 ci: remove changesets infrastructure
Remove the entire changesets-based release system:
- .changeset/ config directory
- .github/actions/changesets-action/ custom fork (34 files)
- @changesets/assemble-release-plan patch
- @changesets/cli dependency
- Old release and prerelease workflows
- Legacy release scripts (check-allowed, generate-changelog, publish-snapshot)
- Stale paths-ignore entries in CI workflows
2026-04-10 22:20:32 -07:00
Jordan Ritter b41fc64e2e fix: showcase drift detection compares against showcase-affecting commits, not HEAD (#3758)
## Summary

The showcase image drift detection compared image tags against `main`
HEAD SHA, but deploys only trigger when `showcase/` or
`examples/integrations/` paths change. Any non-showcase commit to main
(package bumps, workflow changes, docs, etc.) made ALL images appear
stale, triggering unnecessary rebuild workflows and Slack alerts.

## Root Cause

```bash
# Before: always stale after non-showcase commits
MAIN_SHA=$(git ls-remote ... main | cut -f1)
```

## Fix

Query the GitHub API for the last commit that actually touched
showcase-related paths, then check image tags against those SHAs:

```bash
SHOWCASE_SHA=$(gh api "repos/.../commits?path=showcase&per_page=1" --jq '.[0].sha')
EXAMPLES_SHA=$(gh api "repos/.../commits?path=examples/integrations&per_page=1" --jq '.[0].sha')
# Image is up-to-date if it matches EITHER SHA
```

## Impact

- No more false-positive drift alerts flooding #oss-alerts
- No more unnecessary rebuild triggers for every non-showcase commit
- Drift detection now only fires when showcase code actually changed but
images weren't rebuilt

🤖 Generated with [Claude Code](https://claude.com/claude-code)
2026-04-10 13:19:55 -07:00
Jordan Ritter aafcfccb35 fix: showcase drift detection compares against showcase-affecting commits, not HEAD
The drift check compared image tags against main HEAD SHA, but deploys
only trigger when showcase/ or examples/integrations/ paths change. Any
non-showcase commit to main made ALL images appear stale, triggering
unnecessary rebuild workflows and Slack alerts.

Fix: query the GitHub API for the last commit that touched each path
and check image tags against those SHAs instead.
2026-04-10 13:17:28 -07:00
Jordan Ritter 82aaaefbae fix: use npm ci instead of pnpm install for showcase drift detection tests 2026-04-10 11:30:34 -07:00
Jordan Ritter 5cc3e04033 fix: debounce image drift alerts — only alert when stale set changes, not every 15min 2026-04-10 11:15:37 -07:00
Jordan Ritter e5b323902e fix: disable LFS in showcase drift detection checkout (fixes LFS fetch failures) 2026-04-10 11:13:35 -07:00
Jordan Ritter 49861ae3b4 ci: refactor showcase_deploy from 23 duplicate jobs to dynamic matrix
Replaced 23 identical build jobs with one parameterized matrix job.
1200 lines to ~250. Service config as JSON, matrix generated from
path-filter results. Shell special cases (LFS, build-args, custom
Dockerfile) handled via matrix properties and dedicated prep step.
2026-04-10 10:37:51 -07:00
Jordan Ritter d55870c499 ci: consolidate commitlint into static_quality, add auto-fix on PRs
Merged standalone commitlint into static_quality as 4th parallel job.
Upgraded all actions to v4, added concurrency group. Format job now
auto-fixes and commits back to same-repo PR branches. Commitlint
posts helpful PR comment with valid prefixes on failure.
2026-04-10 10:37:51 -07:00
Jordan Ritter 189e20424b ci: add concurrency groups to test workflows
Added cancel-in-progress concurrency to e2e_dojo, e2e_examples,
test_runtime-servers, and test_unit. Added pnpm cache to test_unit.
2026-04-10 10:37:51 -07:00