chore: v3 cleanup — janitorial + testing-app reshape#1397
Merged
Conversation
Prune stale artifacts left over from removed packages and test apps: - Delete empty apps/testing husks: auth-package-app, cloud-deployment, webrtc-test, vite-rsc-app, standalone-agent - Drop vite-rsc references from apps/testing/package.json, scripts/test-framework-demos.sh, and playwright.frameworks.config.ts - Remove scripts/run-cloud-tests.sh (targeted deleted cloud-deployment app) - Remove @agentuity/frontend path alias from integration-suite tsconfig - Delete e2e/frameworks/vite-rsc.pw.ts - Delete stray packages/agentuity-claude-code.zip artifact - Delete orphaned eslint.config.mts (repo uses Biome, no eslint deps) - Update .vscode/settings.json to use Biome (dropped ESLint/Prettier hints) Typecheck, build, and lint all pass.
Every test in e2e/*.pw.ts targeted features that no longer exist in v3
(workbench, frontend/React, runtime-injected analytics, WebRTC signaling,
RPC client, EventStream manager, Vite React preamble, runtime HMR). The
target app apps/testing/e2e-web was also gutted to a toy Hono server that
serves none of the routes the tests expected, so coverage was 0%.
A fresh framework-agnostic e2e suite is planned; tracked in project
memory.
Changes:
- Delete e2e/{basic,analytics,debug-analytics,debug-beacon,hmr,preamble,
rpc,streams,webrtc,workbench}.pw.ts
- Delete e2e/global-setup.ts, e2e/global-teardown.ts
- Delete playwright.config.ts (playwright.frameworks.config.ts stays)
- Delete scripts/run-e2e-tests.sh, scripts/test-e2e.sh
- Drop test:e2e, test:e2e:ui, test:e2e:headed, test:ci:e2e from root
package.json
- Drop run-e2e-tests.sh from test:ci; drop run-cloud-tests.sh (already
removed) and run-e2e-tests.sh calls from test-ci-all.sh
- Remove playwright.config.ts from root tsconfig.json exclude list
- Update scripts/README.md and scripts/prepare-sdk-for-testing.sh hints
Kept:
- apps/testing/e2e-web (has real bun:test unit tests wired into CI
directly via package-smoke-test.yaml)
- playwright.frameworks.config.ts + e2e/frameworks/ (tanstack + nextjs
demo tests, still valid)
Typecheck + lint clean.
Test-app consolidation:
1. Delete apps/testing/queues (the @agentuity/server Queue API test). We
already exercise that surface from the integration-suite; this was a
duplicate standalone harness.
- Delete apps/testing/queues/
- Delete scripts/test-queues.sh
- Drop test:queues from root package.json
- Drop queue-sdk-test job from .github/workflows/package-smoke-test.yaml
(queue-cli-test which exercises CLI commands stays.)
2. Rename apps/testing/queue -> apps/testing/queue-client, package name
queue-test -> queue-client-test, and update test:services:queue script.
Unambiguous now that queues/ is gone, and consistent with other
service-client test apps.
3. Rebuild apps/testing/svelte-web as a proper SvelteKit demo that mirrors
tanstack-start:
- SvelteKit 2 + svelte 5 runes
- @sveltejs/adapter-node for buildpack pipeline
- Translation demo via @ai-sdk/openai + ai, routed through Agentuity
AI Gateway (OPENAI_BASE_URL injected by agentuity dev)
- Routes: / (translate UI), /about, /api/translate, /api/health
- Drops @agentuity/runtime and @agentuity/schema deps
- bunfig.toml scopes bun test to ./test/ so build output doesn't
confuse test discovery
- .gitignore so .svelte-kit/, build/ etc. don't get linted/checked
4. Wire svelte-web into the demo pipeline:
- scripts/test-dev.sh adds svelte-web to ALL_APPS
- scripts/test-framework-demos.sh adds --svelte-only and runs the
SvelteKit block (mirrors tanstack/nextjs)
- playwright.frameworks.config.ts adds svelte project
- e2e/frameworks/svelte.pw.ts mirrors tanstack.pw.ts (translate UI +
AI Gateway + /about navigation)
- apps/testing/package.json: test:frameworks:svelte, fix broken
build:tanstack/nextjs scripts (were calling nonexistent build:agent)
The existing framework-demo-test GitHub Actions job picks up svelte
automatically via the updated test-framework-demos.sh.
Typecheck, svelte-check, bun test, biome check, and vite dev all clean.
Brings nextjs-app to parity with tanstack-start and svelte-web so all
three framework demos exercise the same AI Gateway translation flow via
agentuity dev.
Changes:
- app/page.tsx: client component with translation UI (same textarea +
two selects + translate button + .output result) matching tanstack
and svelte selectors
- app/about/page.tsx: new /about route with <Link href="/">Home</Link>
- app/api/translate/route.ts: new POST handler using @ai-sdk/openai +
ai, prompt-style translation returning {translation, tokens, model,
toLanguage}
- app/api/health/route.ts: kept as-is
- app/api/echo/route.ts: deleted (unused)
- app/layout.tsx: imports app/globals.css + adds metadata
- app/globals.css: new, shared visual style matching tanstack/svelte
- package.json: adds @ai-sdk/openai ^3.0.0 and ai ^6.0.0; drops unused
hono
- test/index.test.ts: expands structure checks to 6 tests covering new
routes
- e2e/frameworks/nextjs.pw.ts: expanded from 2 tests to 4 to mirror
tanstack.pw.ts (home translate UI, AI Gateway translation, /about
navigation) plus the existing /api/health check
- tsconfig.json: reformatted by biome
New: apps/testing/nextjs-app/.gitignore (Next.js defaults — .next, out,
next-env.d.ts, .env.local, etc.). Verified no build artifacts were
previously committed (only 8 source files were tracked).
Verification:
- bunx tsc --noEmit ✓
- bun test ✓ 6 pass, 3 skip
- bun run build ✓ standalone output, 4 routes (/, /about,
/api/translate, /api/health)
- dev smoke ✓ /, /about, /api/health respond on :3099
- bunx biome check . ✓ clean
Contributor
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
📦 Canary Packages Publishedversion: PackagesInstallAdd to your {
"dependencies": {
"@agentuity/schedule": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-schedule-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/telemetry": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-telemetry-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/hono": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-hono-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/postgres": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-postgres-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/email": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-email-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/adapter": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-adapter-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/core": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-core-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/sandbox": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-sandbox-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/local": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-local-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/coder-tui": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-coder-tui-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/queue": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-queue-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/vector": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-vector-3.0.0-alpha.6-c7e589a.tgz",
"create-agentuity": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/create-agentuity-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/cli": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-cli-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/claude-code": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-claude-code-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/drizzle": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-drizzle-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/task": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-task-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/server": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-server-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/analytics": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-analytics-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/schema": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-schema-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/db": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-db-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/runtime": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-runtime-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/keyvalue": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-keyvalue-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/migrate": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-migrate-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/webhook": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-webhook-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/coder": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-coder-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/stream": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-stream-3.0.0-alpha.6-c7e589a.tgz",
"@agentuity/opencode": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-opencode-3.0.0-alpha.6-c7e589a.tgz"
}
}Or install directly: bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-schedule-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-telemetry-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-hono-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-postgres-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-email-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-adapter-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-core-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-sandbox-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-local-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-coder-tui-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-queue-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-vector-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/create-agentuity-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-cli-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-claude-code-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-drizzle-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-task-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-server-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-analytics-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-schema-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-db-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-runtime-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-keyvalue-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-migrate-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-webhook-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-coder-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-stream-3.0.0-alpha.6-c7e589a.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/3.0.0-alpha.6-c7e589a/agentuity-opencode-3.0.0-alpha.6-c7e589a.tgz |
The vite-react-app was a static SPA demo wired only to local scripts/test-dev.sh — no Playwright coverage, no CI, no unique value beyond what tanstack-start and the other framework demos already exercise. If we later want a dedicated 'static SPA + injected static server' demo for the buildpack pipeline, it should be scaffolded fresh with a clearer purpose. - Delete apps/testing/vite-react-app/ - Drop vite-react-app from scripts/test-dev.sh ALL_APPS
Restructures the testing layout:
apps/testing/** -> tests/frameworks/ | tests/services/ | tests/integration/
e2e/frameworks/*.pw.ts -> tests/frameworks/<app>/tests/e2e.pw.ts (colocated)
New shape:
tests/
frameworks/ tanstack-start, nextjs-app, svelte-web (full e2e demos)
services/ db, email, keyvalue, vector, queue, sandbox, schedule, task, webhook
integration/ e2e-web, integration-suite, oauth, standalone-backend
package.json, README.md
Playwright specs now live next to the app they target. structure.test.ts
(was test/index.test.ts) lives in the same tests/ folder.
Renamed apps/testing/queue-client -> tests/services/queue (suffix no longer
needed now that the queue-API duplicate was deleted earlier in this branch).
Also removes broken plumbing that was never wired to CI:
- scripts/run-integration-tests.sh (called a nonexistent ci-test.sh)
- scripts/test-integration-suite.sh (same)
- scripts/test-ci-all.sh (called the above)
- root package.json: test:ci, test:ci:all, test:ci:integration, test:ci:prepare
- 'bun run test:ci' removed from the 'all' script
New CI coverage — wires each service client into a new
service-client-test job in .github/workflows/package-smoke-test.yaml,
running each tests/services/<svc>/index.ts against the live cloud using
AGENTUITY_SDK_KEY. Also extends testing-apps-test to run the new
structure.test.ts files in nextjs-app and svelte-web.
Path updates:
- package.json: workspaces adds tests/**; typecheck:apps, build:apps,
test:services:*, test:standalone, clean now point at tests/*
- tests/package.json: internal scripts rewritten for new subtrees
- playwright.frameworks.config.ts: testDir ./tests/frameworks,
per-project testMatch tests/<app>/tests/e2e.pw.ts
- tsconfig.json: exclude 'e2e' -> 'tests'
- scripts/test-framework-demos.sh, scripts/test-dev.sh,
scripts/install-sdk-tarballs.sh: apps/testing/ -> tests/
- scripts/README.md: rewritten to reflect the new tree and CI matrix
- .github/workflows/package-smoke-test.yaml: testing-apps-test paths +
new service-client-test job
- packages/cli/src/runtime-bootstrap.md, packages/opencode/src/agents/{scout,expert-backend}.ts,
packages/vscode/{README.md,.vscode/launch.json}, examples/README.md:
update stale path refs (launch.json and vscode README targeted a
nonexistent auth-app — now point at tests/integration/standalone-backend)
apps/ now contains only create-agentuity and docs.
Verification:
- bun install ✓
- bun run build ✓
- bun run typecheck ✓ all 4 apps + 29 packages
- bun test (all 6 targets) ✓ 28 pass across integration + frameworks
- playwright --list ✓ 10 tests across tanstack/nextjs/svelte
- bunx biome check . ✓ clean
- bash -n on all scripts ✓ clean
Restructures the top-level directory tree now that 'apps/' only held two
unrelated things:
apps/create-agentuity -> packages/create-agentuity (it's a package)
apps/docs -> docs (it's the site)
apps/ -> deleted
And removes the old top-level docs/ dir of design notes, which had stale
content for removed packages:
docs/webrtc-architecture.md (removed `@agentuity/frontend` WebRTC)
docs/webrtc-scaling-sfu.md (same)
docs/webrtc-turn-configuration.md (same)
docs/async-thread-state.md (orphan design doc, no inbound links)
docs/recipes/auth0.md (removed `@agentuity/auth`)
docs/recipes/clerk.md (same)
docs/recipes/drizzle-integration.md (orphan, superseded by apps/docs site)
docs/testing.md (176-line guide — its conventions are
now inlined into root AGENTS.md)
Resulting top-level:
.github/ biome.json bunfig.toml docs/ examples/
package.json packages/ README.md scripts/ snapshots/
tests/ tsconfig.json ...
Path updates:
- package.json: workspaces ["packages/*", "docs", "tests/**"]
(was packages/*, apps/**, tests/**)
- AGENTS.md: replaces the docs/testing.md link with an inline testing
section covering test/ location convention, tsconfig.test.json split,
@agentuity/test-utils usage, and a pointer to the tests/ tree.
(Leaves the stale architecture table alone — that's docs rewrite
territory, memory #105.)
- scripts/publish.ts: drops the appsDir constant and the three apps/*
iteration loops (version bump, workspace-restore, publishable scan).
Removes apps/*/package.json from the git-checkout revert path. The
create-agentuity-publishes-last ordering is preserved via the existing
sort in getPublishablePackages() — create-agentuity is just a package
now.
- .github/workflows/sync-docs.yml: paths trigger 'apps/docs/src/web/content/**'
-> 'docs/src/web/content/**'; bin/*.sh script paths updated
- .github/workflows/sync-docs-full.yml: same bin/*.sh updates
- .github/workflows/snapshot.yaml: 'cd apps/docs && ... && cd ../..'
-> 'cd docs && ... && cd ..'
- snapshots/sdk-explorer.yaml: 'dir: apps/docs' -> 'dir: docs'
- docs/AGENTS.md, docs/package.json, docs/bin/*.sh,
docs/src/web/components/HandlerContextDemo.tsx: internal apps/docs
self-references -> docs
Verification:
- bun install ✓
- bun run build ✓
- bun run typecheck ✓ all packages + 4 integration apps
- bun test in all 7 test targets ✓ 38 pass, 17 skip
- bunx biome check . ✓ clean (pre-existing version info notice only)
- bunx playwright test --list ✓ 10 tests in 3 framework specs
- Search for stray apps/ references ✓ none outside .next/ and
opencode/dist/ (build artifacts)
Adds a repo-scoped pi skill under .agents/skills/service-docs-sync that reminds contributors to update the matching docs page whenever they edit a service-client package. Scope: just the service-client packages (keyvalue, vector, stream, queue, email, db, schedule, task, webhook, sandbox). Not general-purpose docs maintenance — that's memory #105 territory. The skill: - Lists each package -> docs page mapping explicitly - Describes 'almost always user-facing' categories (new exports, changed signatures, changed defaults, new errors, new env vars, wire format changes) - Describes 'sometimes user-facing' and 'not user-facing' categories - Provides a 6-step workflow (diff -> read docs -> decide -> update -> verify -> commit) - Calls out common anti-patterns ('I'll do it later', 'someone else owns docs', 'only a bug fix') Also drops the obsolete .gitignore block that was hiding all .agents/skills/* with per-skill allowlist exceptions — the allowlist no longer matches current skill structure (github-issue was tracked but not excepted, new skills would have been silently ignored).
|
The latest Agentuity deployment details.
|
create-agentuity was the only package with bin.js / bin.test.js at the
root and a no-op build, which broke scripts/build-sdk.sh's dist/
verification. Converting it to a standard TS package brings it in line
with every other package and lets tsc --build handle it.
Structure:
- src/index.ts — exports getCliVersionSpecifier
- src/bin.ts — the #!/usr/bin/env node entry (spawns bunx
@agentuity/cli@<tag>)
- test/index.test.ts — same 14 tests, now imports from src/
- tsconfig.json — standard shape (extends tsconfig.base.json)
package.json changes:
- bin: ./bin.js -> ./dist/bin.js
- adds main + types + exports fields pointing at dist/
- files: ["bin.js"] -> ["dist", "README.md"]
- scripts: no-op build -> real bunx tsc --build; adds clean, typecheck,
prepublishOnly matching other packages
- devDeps: adds @types/bun, typescript
Runtime note: dist/bin.js reads its own package.json via
readFileSync(resolve(__dirname, '..', 'package.json'), 'utf8') instead
of createRequire, which is simpler and Node-native. Users installing
create-agentuity via 'bun create agentuity' still get the same behaviour
— package.json sits one level up from dist/ in the published tarball.
Root tsconfig.json adds packages/create-agentuity to its references so
'bunx tsc --build' picks it up.
Verification:
- bun install ✓ (bun.lock updated)
- bun run build ✓
- bun run typecheck ✓ 29 packages + 4 apps clean
- bash scripts/build-sdk.sh ✓ now lists 'All 28 packages built
successfully' (create-agentuity
now produces dist/)
- cd packages/create-agentuity && bun test ✓ 14/14 pass
The vite-react template's src/index.css uses `@import 'tailwindcss'` (Tailwind v4), but the framework scaffold config did not install tailwindcss nor register the @tailwindcss/vite plugin. This caused `vite build` to fail in the smoke test with: [postcss] ENOENT: no such file or directory, open 'tailwindcss' Fix by: - Adding tailwindcss and @tailwindcss/vite to vite-react devDependencies - Overlaying a vite.config.ts that registers the tailwindcss() plugin alongside @vitejs/plugin-react
Adds an end-to-end test that scaffolds a fresh Agentuity project using
the latest published create-agentuity@1, then runs the migrate tool
through v1→v2 and v2→v3, finally exercising bun install + tsc against
locally built SDK tarballs.
The suite is gated behind MIGRATE_CHAIN_TEST=1 so default `bun test`
remains fast. CI will run it as a dedicated job.
Structure:
packages/migrate/test/chain/
├── prepare-tarballs.ts wraps scripts/prepare-sdk-for-testing.sh
├── scaffold.ts scaffolding + tarball-override helpers
├── migrate-chain.test.ts the test (skipped by default)
└── README.md
The harness currently fails on the final step (bun install) because the
v2→v3 migrator bumps deleted packages (@agentuity/evals, @agentuity/frontend,
@agentuity/workbench) to ^3.0.0 \u2014 a version that doesn't exist for those
packages (they were removed in v3 as part of the 'eject' model). That
failure, plus other TS errors produced by the chain, will be fixed in
follow-up commits against this test.
The v2\u2192v3 package.json transform was bumping every @agentuity/* dep it found to ^3.0.0 \u2014 including @agentuity/evals, @agentuity/frontend, and @agentuity/workbench, which were removed entirely in v3 as part of the 'eject' model. Resolving ^3.0.0 for these failed with: error: No version matching '^3.0.0' found for specifier '@agentuity/evals' Fix by introducing PACKAGES_REMOVED_IN_V3 \u2014 a hardcoded set of v2-only packages \u2014 and deleting matches from dependencies/devDependencies before the bump step, then skipping them in the bump loop so they don't come back. Exposed by packages/migrate/test/chain. `bun install` now succeeds after the full v1\u2192v2\u2192v3 chain; remaining failures are in the agent/route transforms themselves (covered by follow-up commits).
…cements
Three fixes to the v2\u2192v3 routes + runtime-cleanup path so route files
don't end up with dangling references after the migration:
1. `Env` re-route: imports of `Env` from @agentuity/runtime are rewritten
to a generated local types helper at src/types/hono-env.ts which
re-exports `{ Variables: Services }` from @agentuity/hono.
2. `validator` strip: Agentuity's v2 validator middleware
(`validator({ input })` / `validator({ output })`) and the
auto-generated `<agent>.validator()` method are both replaced with
TODO comments \u2014 v3 expects manual zod parsing inline.
3. The new `stripAgentuityValidators` helper is applied both inside
`transformRouteServices` and during the broader runtime-cleanup
sweep so route files that have no service usage (and therefore
skip the service transform) still get their validator calls
stripped.
Exposed by packages/migrate/test/chain \u2014 after this change, the chain
test's typecheck errors drop from ~15 to 4, all of which are the same
root cause (`c.var.thread` \u2014 a v2 concept with no v3 equivalent) and
are handled in follow-up commits.
v3 is an 'eject' \u2014 createAgent, thread state, sessionId, ctx.config
and <agent>.run() / <agent>.validator() all go away. Previously complex
agents (setup/shutdown/onEvent) bailed out with a comment and left the
source intact, producing broken output referencing createAgent(\u2026).
Changes in this commit:
1. Detection: src/agent/<name>/index.ts (the scaffolder layout) was
being skipped as 'barrel'. Only the top-level src/agent/index.ts is
the real barrel; subdirectory index.ts files are agent bodies.
2. Agent transform:
- New force-convert path for complex agents: hoists setup() body to
a module-level `__runSetup()` lazy-init block, emits per-key
async getters (get_client, get_groq, etc.), rewrites ctx.config.X
\u2192 X references in the handler body.
- ctx.thread.*, ctx.sessionId, ctx.app.* are stubbed out with
'v3-no-session-id' / (undefined as any) plus inline TODO comments.
The rewrite is AST-based so we only touch the outermost chain at
each location and don't mangle type arguments or call sites.
- Prepends a review banner so the user knows which agent was
auto-ejected and why.
3. Route helpers (routes.ts):
- rewriteV2AgentMethods: <agent>.run(data) \u2192 <agent>(data) and
c.req.valid('json') \u2192 await c.req.json().
- stubV2HonoContext: c.var.thread.*(\u2026)<T>(\u2026) and c.var.sessionId
\u2192 typed stubs. The regex accepts property access, generic type
arguments, and call sites in any order so chains like
.state.get<T>('key') collapse correctly.
4. migrate-v3 orchestrator: these route helpers now run during the
broader runtime-import cleanup sweep so files that had no service
usage (and therefore skipped transformRouteServices) still get
their v2 method calls and context accessors rewritten.
Chain test progress: from 15 type errors after v2\u2192v3 down to 7, all
concentrated in (a) the eval.ts file that uses @agentuity/evals +
agent.createEval (handled in a follow-up by deleting eval files) and
(b) the plain-function handler losing its param type annotations (also
follow-up).
…, type-annotate extracted handlers Final transform fixes so the v1\u2192v2\u2192v3 chain test typechecks clean end to end: 1. Eval files: delete every *.ts/*.tsx that imports '@agentuity/evals'. The evals framework was removed in v3 (no agent.createEval, no ctx.* on eval handlers), so files that use it can't be mechanically ported \u2014 dropping them is the honest thing to do. 2. ctx.config.<key> now becomes `(await get_<key>())` inline instead of bare `<key>`. The hoisted `get_<key>()` helper we emit at the top of the file returns a promise, so every use site must await. 3. When the original handler's parameter had no type annotation (the v2 scaffold relied on createAgent generics for inference), we now inject `: any` on extraction so strict-mode TypeScript doesn't complain about implicit-any on destructured members. With these three changes the chain test passes all four phases: \u2022 scaffold v1 \u2022 migrate v1\u2192v2 \u2022 migrate v2\u2192v3 \u2022 bun install + tsc \u2014 zero type errors The emitted v3 code is a working starting point \u2014 every v2 concept that has no v3 equivalent (ctx.thread.*, ctx.sessionId, ctx.app.*, agent.validator, validator() middleware) is stubbed with a typed placeholder + TODO comment rather than silently dropped.
Adds a `Migrate Chain (v1 \u2192 v2 \u2192 v3)` job to package-smoke-test.yaml that: 1. Installs dependencies 2. Builds and packs the SDK tarballs 3. Runs the gated chain test via MIGRATE_CHAIN_TEST=1 The job runs in parallel with the other smoke jobs and takes ~1\u20132 minutes end to end. It catches migration regressions before release \u2014 the chain exercises the full scaffold \u2192 migrate \u2192 install \u2192 typecheck path against what users actually get when they run `bun create agentuity@1` / @2 on npm today.
v3 is an eject \u2014 the idiomatic path for user-owned schemas is zod, not
the @agentuity/schema helper. This commit adds a transform that:
\u2022 Replaces `import { s } from '@agentuity/schema'` with
`import { z } from 'zod'`
\u2022 Rewrites every s.<builder>() call (object, string, number, array,
enum, union, literal, optional, nullable, record, coerceX, \u2026) to
the matching z.<builder>() call
\u2022 Rewrites s.infer<\u2026> to z.infer<\u2026>
\u2022 Converts variadic s.union(a, b, c) to array-form z.union([a, b, c])
(the only shape difference between the two libraries)
\u2022 Stubs s.toJSONSchema with a TODO comment pointing at zod's
.toJSON() (v4) or zod-to-json-schema \u2014 we don't auto-translate
that one because the output shape differs.
Wired into the v2\u2192v3 orchestrator: if any file was actually ported,
the package.json update step adds `zod@^4.0.0` and drops
`@agentuity/schema` from dependencies/devDependencies.
Chain test still green after the port \u2014 all four phases pass.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Low-risk v3 cleanup pass on top of
v3. Four commits removing dead weight left behind by the workbench/frontend/react/auth/evals/runtime package removals, plus reshaping theapps/testing/framework demos so they're consistent with each other.Commits
chore: v3 low-risk cleanup— Stray artifacts: emptyapps/testing/husks (auth-package-app, cloud-deployment, webrtc-test, vite-rsc-app, standalone-agent), zombienode_modules-only dirs underpackages/(react, frontend, workbench, svelte, pi), orphanedeslint.config.mts(repo uses Biome, no ESLint deps installed), stale@agentuity/frontendpath alias in integration-suite tsconfig,scripts/run-cloud-tests.sh, and oldagentuity-claude-code.zip. Updates.vscode/settings.jsonto Biome.chore: remove obsolete e2e playwright suite— 2,560 lines of dead Playwright tests targeting removed features (workbench, frontend/React, runtime-injected analytics, WebRTC, RPC client, EventStream, Vite React preamble, runtime HMR). Target appapps/testing/e2e-webwas already gutted to a toy Hono server that served none of the routes these tests expected. Dropsplaywright.config.ts,e2e/{global-setup,global-teardown}.ts,scripts/{run-e2e-tests,test-e2e}.sh, and related roottest:e2e*/test:ci:e2escripts. Framework-demo e2e (playwright.frameworks.config.ts) ande2e-web's ownbun:testunit tests (wired directly into CI) are kept. See project memory feat(cli): add cloud redis show command #108 for the planned fresh v3 e2e suite.chore(testing): reshape apps/testing — svelte demo + queue rename— Deletesapps/testing/queues/(duplicate@agentuity/serverQueue API harness already covered by integration-suite), dropsscripts/test-queues.shand thequeue-sdk-testCI job. Renamesapps/testing/queue→apps/testing/queue-clientfor clarity (the other exists only as the CLI test now). Rebuildsapps/testing/svelte-webas a proper SvelteKit 2 + Svelte 5 runes app withadapter-node, an AI-Gateway translation demo (@ai-sdk/openai+ai),/aboutroute, and/api/health+/api/translateendpoints — mirroring the tanstack-start shape. Drops zombie@agentuity/runtimeand@agentuity/schemadeps. Wires svelte intoscripts/test-dev.sh,scripts/test-framework-demos.sh(new--svelte-onlyflag),playwright.frameworks.config.ts, andapps/testing/package.json. Addse2e/frameworks/svelte.pw.tsmirroringtanstack.pw.ts. Fixes brokenbuild:tanstack/build:nextjsscripts inapps/testing/package.json(were calling nonexistentbuild:agent). Existingframework-demo-testCI job picks up svelte automatically.chore(testing): upgrade nextjs-app to AI Gateway translation demo— Brings nextjs-app to parity with tanstack-start and svelte-web. Newapp/about/page.tsx, newapp/api/translate/route.tsusing@ai-sdk/openai, newapp/globals.cssshared visual design, deps updated to add@ai-sdk/openai+aiand drop unusedhono. Playwright spec expanded from 2 → 4 tests matching the other framework demos. First-time.gitignoreadded (no build artifacts had previously leaked into git — verified).Result
/aboutnav/api/healthVerification
bun run typecheck— ✓ all 4 apps + 29 packagesbun run typecheck:svelte(svelte-check) — ✓ 0 errorsbun testin each upgraded app — ✓ passesbun run buildin svelte-web and nextjs-app — ✓ produces adapter-node and standalone outputbunx biome check .— ✓ clean (only pre-existing version info notice)/about,/api/health) — ✓What was intentionally not touched
Tracked as project memory, to be handled separately:
apps/docs/src/web/public/frontend/*, auth recipes, cookbook pages. Owned by the docs rewrite; needs real authorship, not grep-and-delete. (memories fix: prevent catch-all route from intercepting API routes #105, API context type hints can be better #102)apps/testing/vite-react-app(local-only viatest-dev.sh, no Playwright) and the per-service test apps (db,email,keyvalue,vector,queue-client,sandbox,schedule,task,webhook). All local-only. (memory Add type inference test for router context variables #106)@agentuity/runtimestub lifetime,@agentuity/schemasunset,@agentuity/migraterework. (memory Add helpful error messages for Agent vs Route context misuse #107)@agentuity/analytics,@agentuity/honomiddleware, buildpack pipeline,agentuity dev/create, and service clients. (memory feat(cli): add cloud redis show command #108)Branching
Targets
v3, notmain.