Skip to content

Add CI pipeline with linting, formatting, and smoke tests#2

Merged
teallarson merged 15 commits intomainfrom
teallarson/add-ci-pipeline
Feb 25, 2026
Merged

Add CI pipeline with linting, formatting, and smoke tests#2
teallarson merged 15 commits intomainfrom
teallarson/add-ci-pipeline

Conversation

@teallarson
Copy link
Copy Markdown
Collaborator

@teallarson teallarson commented Feb 25, 2026

Ensures CLI, templates, and generated code all lint, format, and build.

Summary

  • ESLint v9 + Prettier for all TypeScript/JS across src/ and templates/
  • Ruff for Python linting/formatting in templates/langchain/
  • GitHub Actions CI with 3 jobs:
    • lint-and-build — ESLint + Prettier + typecheck + build on Node 18 & 22
    • lint-python — Ruff check + format on Python template files
    • smoke-test-templates — Scaffolds each template (ai-sdk, mastra, langchain) and verifies it builds/lints
  • Generated TS projects now ship with Prettier config and format/format:check scripts
  • Fix existing lint issues (unused imports, empty catch blocks) and apply consistent formatting

Test plan

  • npm run lint passes
  • npm run format:check passes
  • npm run typecheck passes
  • npm run build passes
  • ruff check templates/langchain/ passes
  • ruff format --check templates/langchain/ passes
  • All 3 CI jobs pass green in GitHub Actions

🤖 Generated with Claude Code

teallarson and others added 13 commits February 25, 2026 10:54
- ESLint v9 + Prettier for TypeScript/JS across src/ and templates/
- Ruff for Python linting/formatting in templates/langchain/
- GitHub Actions CI with 3 jobs: lint-and-build (Node 18/22),
  lint-python (Ruff), and smoke-test-templates (scaffold + build)
- Generated TS projects now ship with Prettier config
- Fix existing lint issues (unused imports, empty catch blocks)
- Apply consistent formatting across all source files

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add Development section to README with scripts, linting/formatting
  details, CI overview, and local testing instructions
- Create root CLAUDE.md with project structure, commands, and CI info
- Update template CLAUDE.md files with format/ruff commands

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Key on both the root lockfile and template package.json so that
scaffolded project deps (Next.js, React, etc.) are cached across runs.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Next.js requires useSearchParams() to be wrapped in a <Suspense>
boundary for static generation. Extracted dashboard content into
a DashboardContent component wrapped by the default export.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Replace bare `Function` type with typed signature in plan-route-body.hbs
- Remove setState-in-useEffect pattern in chat-panel.tsx (derive error instead)
- Add fail-fast: false to smoke test matrix so all templates report independently
- Fix stale "Node 18 & 22" reference in README

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add `typecheck` script (`tsc --noEmit`) to ai-sdk and mastra template package.json
- Add explicit type check step in smoke test CI (runs before build for clearer errors)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add ty.toml for Python type checking (matches Arcade monorepo tooling)
- Enhance ruff.toml with bugbear, bandit, comprehensions, simplify, pyupgrade rules
- Fix all new Ruff violations (contextlib.suppress, raise-from, set comprehension, etc.)
- Replace py_compile with ruff + ty in CI smoke tests for langchain template
- Update langchain CLAUDE.md with ty command

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Ruff isort requires sqlalchemy (third-party) to be grouped before
alembic/app (first-party) when running from the project directory.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
ty doesn't yet understand Pydantic field aliases or SQLAlchemy Column
types, causing false positives with ChatAnthropic/ChatOpenAI and ORM
fields. Ignore these rules until ty matures.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
ty doesn't narrow through hasattr() or isinstance+continue patterns,
causing false positives with FastAPI route inspection and asyncio
gather results.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Align CLAUDE.md with the current workflow, which runs lint-and-build on Node 22 only.

Co-authored-by: Cursor <cursoragent@cursor.com>
@teallarson teallarson marked this pull request as ready for review February 25, 2026 17:06
teallarson and others added 2 commits February 25, 2026 12:10
Reuse the built CLI artifact across smoke jobs, reduce package manager overhead, add pip caching for langchain, and cancel superseded branch runs.

Co-authored-by: Cursor <cursoragent@cursor.com>
Detect changed areas and only run Python linting and per-template smoke checks when relevant, while still running full coverage for shared/core changes.

Co-authored-by: Cursor <cursoragent@cursor.com>
@teallarson teallarson merged commit ea89c1c into main Feb 25, 2026
@teallarson teallarson deleted the teallarson/add-ci-pipeline branch February 25, 2026 17:17
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