Repository navigation
chore: simplify ci - #6905
chore: simplify ci#6905
Conversation
|
π Deployed to the trpc-pr-6905 environment in trpc-sse-and-websockets
|
WalkthroughMoves type-checking from repo-level Turbo/codegen workflows to package-parallel PNPM + Turbo-per-target checks, removes the BigBoi generator and its test, updates CI to run package and PR-gated www typechecks, adjusts Turbo task declarations, adds Prisma hoist exclusions, tweaks small www typings/markup, and deletes the tanstack-start example and related files. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
participant Dev as Developer/CI
participant Root as Root scripts
participant PNPM as pnpm (parallel)
participant Turbo as Turbo
participant PKG as ./packages/* (each)
participant WWW as www
participant TSC as tsc
rect rgba(220,235,255,0.9)
note right of Dev: package-parallel typechecks (pnpm)
Dev->>Root: pnpm typecheck-packages
Root->>PNPM: pnpm run --parallel --filter=./packages/* typecheck
PNPM->>PKG: run `typecheck` script
PKG->>TSC: tsc --noEmit --preserveWatchOutput --pretty
end
rect rgba(235,255,220,0.9)
note right of Dev: www-specific typecheck (Turbo, PR job)
Dev->>Root: pnpm typecheck-www
Root->>Turbo: turbo --filter www typecheck
Turbo->>WWW: run `typecheck` for `www`
WWW->>TSC: tsc --noEmit --preserveWatchOutput --pretty
end
Estimated code review effortπ― 3 (Moderate) | β±οΈ ~25 minutes Possibly related PRs
Suggested labels
Suggested reviewers
Poem
β¨ Finishing Touchesπ§ͺ Generate unit tests
πͺ§ TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR/Issue comments)Type Other keywords and placeholders
CodeRabbit Configuration File (
|
@trpc/client
@trpc/next
@trpc/react-query
@trpc/server
@trpc/tanstack-react-query
@trpc/upgrade
commit: |
There was a problem hiding this comment.
Actionable comments posted: 0
π§Ή Nitpick comments (2)
turbo.json (1)
25-26: Enabling cache for tsc is fine; add lockfile/workspace to inputs to avoid stale caches.Dropping
"cache": falsemeans Turboβs cache now applies totsc. To ensure correct invalidation when deps/graph change, include the package manager artifacts inglobalDependencies(lockfile and workspace manifest). Otherwise, a type surface change via dependency updates could be cached across CI runs.Suggested addition outside this hunk (top of turbo.json):
{ "globalDependencies": [ ".eslintrc.config.js", "tsconfig.json", "tsconfig.build.json", "scripts/**", "pnpm-lock.yaml", "pnpm-workspace.yaml" ] }Optional CI tip: if not already configured, enable Turbo remote caching (e.g., TURBO_TOKEN) to realize the speedup consistently across CI jobs.
package.json (1)
20-20: Drop duplicate --pretty and align filter style for consistency.Minor cleanup and consistency with other scripts that use
--filter={./packages/*}.- "tsc-check": "turbo tsc --filter './packages/*' -- --noEmit --pretty --pretty", + "tsc-check": "turbo --filter={./packages/*} tsc -- --noEmit --pretty",
π Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
π‘ Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
π Files selected for processing (2)
package.json(1 hunks)turbo.json(2 hunks)
β° Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (20)
- GitHub Check: E2E-tests (next-prisma-todomvc)
- GitHub Check: E2E-tests (nuxt)
- GitHub Check: E2E-tests (fastify-server)
- GitHub Check: E2E-tests (.test/ssg)
- GitHub Check: E2E-tests (next-prisma-websockets-starter)
- GitHub Check: E2E-tests (vercel-edge-runtime)
- GitHub Check: E2E-tests (express-server)
- GitHub Check: E2E-tests (next-formdata)
- GitHub Check: E2E-tests (next-prisma-starter)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 20.x)
- GitHub Check: E2E-tests (cloudflare-workers)
- GitHub Check: E2E-tests (express-minimal)
- GitHub Check: E2E-tests (.experimental/next-app-dir)
- GitHub Check: e2e-legacy-node (next-prisma-starter, 20.x)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-starter, 18.x)
- GitHub Check: E2E-tests (Bun) (bun, ubuntu-latest)
- GitHub Check: Test a monorepo using built declaration files
- GitHub Check: E2E-tests (Deno) (deno-deploy)
- GitHub Check: test
π Additional comments (2)
turbo.json (1)
57-58: Typecheck caching: good for CI speed; confirm no non-deterministic env inputs.With caching on, ensure type-checks donβt rely on non-hashed env (beyond the already-listed globalEnv) or time-based codegen. If they do, either add those inputs to
globalEnv/globalDependenciesor keep caching off for this task.package.json (1)
21-21: tsc-watch script verified safe: no missing tsc scripts or codegen dependencies
- We confirmed every package under packages/* defines a
scripts.tscentryβno missing scripts to trigger failures.- No source files import from
__generated__, and no*/__generated__/bigBoidirectories exist; the rootpostinstallalready runspnpm codegen(includingcodegen-tests), so all generated artifacts are in place before watching.- Therefore, switching
tsc-watchtopnpm run --parallel --filter './packages/*' tsc β¦ --watchwonβt break typeβchecking or miss codegen outputs.Optional stylistic polish: unify filter quoting for cross-shell consistency
- "tsc-watch": "pnpm run --parallel --filter './packages/*' tsc --noEmit --preserveWatchOutput --pretty --watch", + "tsc-watch": "pnpm run --parallel --filter {./packages/*} tsc --noEmit --preserveWatchOutput --pretty --watch",
There was a problem hiding this comment.
Actionable comments posted: 4
π§Ή Nitpick comments (9)
www/src/pages/media.tsx (2)
13-16: Add alt text (and consider lazy-loading) for images used in AssetFor accessibility and minor perf wins, provide meaningful alt text and lazily load these decorative/media assets. Using the existing title prop is a reasonable default.
Apply this diff:
- <img - className={`grow self-center ${props.imgClassName}`} - src={props.src} - /> + <img + className={`grow self-center ${props.imgClassName}`} + src={props.src} + alt={props.title} + loading="lazy" + decoding="async" + />
36-44: Handle clipboard write failuresnavigator.clipboard.writeText can reject (e.g., unsupported context, permissions). Add a catch to avoid unhandled promise rejections and aid debugging. Keeps your existing void pattern.
- onClick={() => void navigator.clipboard.writeText(props.value)} + onClick={() => + void navigator.clipboard + .writeText(props.value) + .catch((err) => console.warn('Clipboard write failed', err)) + }www/package.json (1)
21-23: Optional: add a watch variant for local DX.A
"typecheck:watch": "tsc --noEmit --preserveWatchOutput --pretty --watch"entry can speed up local iteration."lint": "eslint --cache src", "typecheck": "tsc --noEmit --preserveWatchOutput --pretty" + ,"typecheck:watch": "tsc --noEmit --preserveWatchOutput --pretty --watch"www/sidebars.ts (1)
2-2: Avoid importing internal Docusaurus type paths to reduce fragility.
@docusaurus/plugin-content-docs/src/sidebars/types.jsis an internal path that can break on upgrades. You can rely on the annotatedSidebarsConfigat the end of the file to type-check usage, and drop the explicit type/import.-import type { SidebarItemCategoryConfig } from '@docusaurus/plugin-content-docs/src/sidebars/types.js'; +// (avoid importing internal Docusaurus types)And remove the explicit annotation:
-const typeDoc: SidebarItemCategoryConfig = { +const typeDoc = {If you prefer explicit checking without internal imports, another option is to keep the import removed and use satisfies against exported
SidebarsConfigshapes:// example (no internal imports) // const typeDoc = { ... } satisfies Parameters<NonNullable<SidebarsConfig['docs']>[number]['items'].push>[0];packages/server/package.json (1)
23-23: Optional: add a watch script for server developers.Mirrors the www suggestion; handy during local development.
"lint": "eslint --cache src", "typecheck": "tsc --noEmit --preserveWatchOutput --pretty" + ,"typecheck:watch": "tsc --noEmit --preserveWatchOutput --pretty --watch"packages/client/package.json (1)
29-29: Optional: add a watch variant here too for parity across packages."lint": "eslint --cache src", "typecheck": "tsc --noEmit --preserveWatchOutput --pretty" + ,"typecheck:watch": "tsc --noEmit --preserveWatchOutput --pretty --watch"turbo.json (1)
50-52: Align Turbo typecheck task with new CI flow (or drop it).CI now runs per-package checks via pnpm, not Turbo. This Turbo task remains unused for packages and is only exercised by the new www job. Either:
- keep it but note itβs intended for www/local workflows, or
- remove it from the global tasks to avoid confusion and rely solely on pnpm for packages.
If you keep it, the current dependsOn ["^build"] is sensible. Please confirm intended usage to avoid drift between tooling.
.github/workflows/main.yml (2)
47-48: Package typechecks no longer depend on upstream buildsβverify this is intentional.Previously Turboβs typecheck depended on "^build". The new pnpm typecheck-packages runs independently and in parallel to build. If any packageβs typecheck requires built d.ts or other artifacts from dependencies, this may flake or miss issues.
Options:
- add needs: [build] to the typecheck job, or
- ensure each packageβs typecheck doesnβt rely on built outputs (pure source/type-only imports), or
- switch back to Turbo for package typechecks to retain "^build" semantics.
Please confirm which invariant you want and we can update the workflow accordingly.
49-58: Enable remote Turbo caching for typecheck-www for consistency and speed.typecheck-www invokes Turbo but this job lacks TURBO_TEAM/TURBO_TOKEN env found in other jobs. Add them if you want remote cache hits on CI.
typecheck-www: needs: [build] runs-on: ubuntu-latest + env: + TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} + TURBO_TEAM: ${{ vars.TURBO_TEAM }} steps: - uses: actions/checkout@v4 with: fetch-depth: 0 - uses: ./.github/setup - run: pnpm typecheck-www
π Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
π‘ Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
π Files selected for processing (16)
.github/workflows/main.yml(1 hunks)package.json(1 hunks)packages/client/package.json(1 hunks)packages/next/package.json(1 hunks)packages/react-query/package.json(1 hunks)packages/react-query/test/bigBoi.test.tsx(0 hunks)packages/server/package.json(1 hunks)packages/tanstack-react-query/package.json(1 hunks)packages/tests/package.json(1 hunks)scripts/generateBigBoi.ts(0 hunks)turbo.json(1 hunks)www/package.json(1 hunks)www/sidebars.ts(2 hunks)www/src/pages/media.tsx(1 hunks)www/src/theme/DocItem/Metadata/index.tsx(1 hunks)www/src/utils/handleSmoothScrollToSection.ts(1 hunks)
π€ Files with no reviewable changes (2)
- packages/react-query/test/bigBoi.test.tsx
- scripts/generateBigBoi.ts
π§° Additional context used
π§ Learnings (1)
π Learning: 2025-06-09T14:01:20.033Z
Learnt from: juliusmarminge
PR: trpc/trpc#6789
File: packages/tanstack-react-query/tsdown.config.ts:1-24
Timestamp: 2025-06-09T14:01:20.033Z
Learning: In the tRPC monorepo, packages/tests and packages/upgrade don't need main/module/types fields in their package.json because tests is not distributed and upgrade just exposes a binary.
Applied to files:
packages/tests/package.jsonpackages/react-query/package.jsonpackage.json
β° Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (20)
- GitHub Check: E2E-tests (nuxt)
- GitHub Check: E2E-tests (tanstack-start)
- GitHub Check: E2E-tests (vercel-edge-runtime)
- GitHub Check: E2E-tests (soa)
- GitHub Check: E2E-tests (.test/internal-types-export)
- GitHub Check: E2E-tests (express-server)
- GitHub Check: E2E-tests (next-formdata)
- GitHub Check: E2E-tests (fastify-server)
- GitHub Check: E2E-tests (.experimental/next-app-dir)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-starter, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 20.x)
- GitHub Check: e2e-legacy-node (next-prisma-todomvc, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-starter, 20.x)
- GitHub Check: E2E-tests (Bun) (bun, ubuntu-latest)
- GitHub Check: Release using pkg.pr.new
- GitHub Check: typecheck-www
- GitHub Check: test
- GitHub Check: Analyze (typescript)
- GitHub Check: Lint and auto-fix
π Additional comments (10)
www/src/pages/media.tsx (1)
95-99: Correct use of crossOrigin="anonymous" on preconnect to fonts.gstatic.comGood fix. crossOrigin expects the enumerated values "anonymous" or "use-credentials"; switching from a boolean-like value to "anonymous" is standards-compliant, prevents credentialed requests to the font CDN, and should satisfy stricter TS/React typings and the new typecheck-www job.
packages/client/package.json (1)
29-29: Standardized per-package typecheck script looks good.Aligns with the new CI flow and is consistent with other packages.
www/package.json (1)
21-23: Adding a dedicated typecheck script for www is aligned with the new CI job.Good to see parity with other packages.
www/sidebars.ts (2)
7-17: Refactor to constant improves readability and reuse.Separating the Typedoc category into
typeDocis a clean improvement.
198-198: Behavior preserved while making the spread more readable.Using
[typeDoc]in the conditional spread keeps semantics unchanged and is easier to scan.packages/server/package.json (1)
23-23: Consistent typecheck script matches repo-wide convention.No issues spotted.
www/src/theme/DocItem/Metadata/index.tsx (1)
7-7: Remove explicit return type β fine to rely on TS inference hereFor a local component, inference keeps noise low and doesnβt weaken type safety. No issues spotted.
packages/next/package.json (1)
30-30: Adopttypecheckscript β consistent with monorepo CIMatches the new parallel typecheck strategy. Looks good.
packages/tests/package.json (1)
6-6: Addtypecheckscript β goodThis aligns the tests workspace with the unified typecheck job. No concerns.
packages/react-query/package.json (1)
21-21: Switch totypecheckscript β approvedConsistent with the broader CI simplification; no functional risks.
There was a problem hiding this comment.
Actionable comments posted: 0
π§Ή Nitpick comments (2)
turbo.json (2)
50-51: Typecheck caching looks good; consider dropping the build dependency to speed CIEnabling cache for pure
tsc --noEmit-style typechecks is typically safe and helpful. Optional: removingdependsOn: ["^build"]can decouple typechecking from builds and speed up CI, unless your type checks require generated build artifacts.Optional tweak:
- "typecheck": { - "dependsOn": ["^build"] - }, + "typecheck": {},If some packages rely on generated types/artifacts, keep the current dependency.
53-54: Avoid caching and simplify dependencies fortest-start(likely e2e/integration)If
test-startlaunches a server and runs integration/e2e tests, it should generally not be cached. Also, since the global"build"task already depends on"^build", specifying both is redundant.Recommended:
- "test-start": { - "dependsOn": ["^build", "build"] - } + "test-start": { + "dependsOn": ["build"], + "cache": false + }Please confirm what
test-startexecutes. If itβs deterministic and not environment-dependent, you may keep caching on, but ensure CI wonβt inadvertently skip execution due to a warm cache.
π Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
π‘ Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
π Files selected for processing (3)
.github/workflows/main.yml(1 hunks)package.json(1 hunks)turbo.json(1 hunks)
π§ Files skipped from review as they are similar to previous changes (2)
- package.json
- .github/workflows/main.yml
β° Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (19)
- GitHub Check: E2E-tests (tanstack-start)
- GitHub Check: E2E-tests (standalone-server)
- GitHub Check: E2E-tests (vercel-edge-runtime)
- GitHub Check: E2E-tests (next-prisma-websockets-starter)
- GitHub Check: E2E-tests (nuxt)
- GitHub Check: E2E-tests (minimal-react)
- GitHub Check: E2E-tests (fastify-server)
- GitHub Check: E2E-tests (next-prisma-starter)
- GitHub Check: E2E-tests (.test/ssg)
- GitHub Check: E2E-tests (.experimental/next-app-dir)
- GitHub Check: E2E-tests (.test/diagnostics-big-router)
- GitHub Check: e2e-legacy-node (next-prisma-todomvc, 20.x)
- GitHub Check: e2e-legacy-node (next-prisma-starter, 20.x)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 20.x)
- GitHub Check: e2e-legacy-node (next-prisma-starter, 18.x)
- GitHub Check: Release using pkg.pr.new
- GitHub Check: E2E-tests (Deno) (deno-deploy)
- GitHub Check: test
π Additional comments (1)
turbo.json (1)
47-48: Review usage of thetest-devTurbo taskIt looks like youβve defined a
test-devtask in your root turbo.json but I canβt find anytest-devscripts in your root or package-level package.json files (only inexamples/β¦). Please confirm whether this task is actually used:β’ File turbo.json (root), lines 44β48:
"test-dev": { "dependsOn": ["^build"] },β’ No
"test-dev"script in root package.json
β’ No"test-dev"script in any packages/*/package.jsonIf you intend to run ad-hoc or watch-mode tests via Turbo, youβll want to disable caching and keep the process alive:
"test-dev": { - "dependsOn": ["^build"] + "dependsOn": ["^build"], + "cache": false, + "persistent": true },Otherwise, if this task isnβt being invoked anywhere, consider removing it to avoid confusion.
There was a problem hiding this comment.
Actionable comments posted: 0
π§Ή Nitpick comments (4)
examples/next-prisma-todomvc/src/server/routers/todo.ts (4)
20-25: Tighten theidinput or drop it to rely on DB defaults.Allowing clients to supply
idas an arbitrary string risks invalid IDs or collisions if the DB generates UUIDs. Either:
- require a proper UUID, or
- remove
idfrom the input and let the DB generate it.Outside this hunk, adjust the schema:
// Option A: keep, but validate z.object({ id: z.string().uuid().optional(), text: z.string().min(1), }) // Option B: remove id entirely (preferred if DB auto-generates) z.object({ text: z.string().min(1), })
36-43: Prevent empty updates by validating at least one field is present.
dataallows both fields to be omitted; Prisma.update({ data: {} })will throw. Add a refinement to require one ofcompletedortext.Outside this hunk, update the input schema:
const EditInput = z.object({ id: z.string().uuid(), data: z.object({ completed: z.boolean().optional(), text: z.string().min(1).optional(), }).refine(d => d.completed !== undefined || d.text !== undefined, { message: 'Provide at least one field to update', path: ['data'], }), })
46-50: Optional micro-optimization: update only rows that need changing.Reduce unnecessary writes by filtering to items not already in the desired state.
- await prisma.task.updateMany({ - data: { completed: input.completed }, - }); + await prisma.task.updateMany({ + data: { completed: input.completed }, + where: { completed: { not: input.completed } }, + });
57-62: Keep return ordering consistent withall.
clearCompletedcurrently returns an unsorted list;allreturns items ordered bycreatedAt: 'asc'. Aligning avoids UI jitter.- return prisma.task.findMany(); + return prisma.task.findMany({ + orderBy: { createdAt: 'asc' }, + });
π Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
π‘ Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
π Files selected for processing (3)
.npmrc(1 hunks)examples/next-prisma-todomvc/src/server/context.ts(0 hunks)examples/next-prisma-todomvc/src/server/routers/todo.ts(3 hunks)
π€ Files with no reviewable changes (1)
- examples/next-prisma-todomvc/src/server/context.ts
π§° Additional context used
𧬠Code graph analysis (1)
examples/next-prisma-todomvc/src/server/routers/todo.ts (2)
examples/next-prisma-todomvc/src/server/trpc.ts (2)
router(9-9)baseProcedure(10-10)examples/next-prisma-todomvc/src/server/prisma.ts (1)
prisma(8-8)
β° Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (20)
- GitHub Check: E2E-tests (next-prisma-todomvc)
- GitHub Check: E2E-tests (soa)
- GitHub Check: E2E-tests (.test/internal-types-export)
- GitHub Check: E2E-tests (.experimental/next-app-dir)
- GitHub Check: E2E-tests (cloudflare-workers)
- GitHub Check: E2E-tests (next-formdata)
- GitHub Check: E2E-tests (express-minimal)
- GitHub Check: E2E-tests (.test/diagnostics-big-router)
- GitHub Check: E2E-tests (.test/ssg)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 20.x)
- GitHub Check: Release using pkg.pr.new
- GitHub Check: E2E-tests (Bun) (bun, ubuntu-latest)
- GitHub Check: e2e-legacy-node (next-prisma-todomvc, 20.x)
- GitHub Check: E2E-tests (Deno) (deno-deploy)
- GitHub Check: e2e-legacy-node (next-prisma-todomvc, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 18.x)
- GitHub Check: Test a monorepo using built declaration files
- GitHub Check: Lint and auto-fix
- GitHub Check: test
- GitHub Check: Analyze (typescript)
π Additional comments (4)
.npmrc (1)
4-8: Confirmed: Repository uses pnpm 9.12.2, which supports negation in hoist patternsVerified that
package.jsonpinspackageManagerto[email protected], comfortably β₯ 7.12.0, so the!-style negations in bothhoist-pattern[]andpublic-hoist-pattern[]are fully supported.examples/next-prisma-todomvc/src/server/routers/todo.ts (3)
2-2: LGTM: direct Prisma import aligns with simplified context.Using a shared
prismaimport is consistent with typical Next.js/TRPC examples and avoids passing DB through ctx when not needed.
6-12: LGTM: simple read with deterministic ordering.Returning tasks ordered by
createdAt: 'asc'is appropriate for the UI.
53-56: LGTM: delete by id and return id.Clear and client-friendly contract; keeps payload small.
There was a problem hiding this comment.
Actionable comments posted: 0
π§Ή Nitpick comments (3)
turbo.json (3)
50-51: Reconsider adding "postinstall" as a dependency of typecheck; prefer hashing lockfile instead.Making
typecheckdepend onpostinstallcan re-run side-effectful lifecycle scripts across the workspace and slow CI. If the goal is to invalidate caches when deps change, hashing the lockfile is safer and conventional.
- Recommended: drop
postinstallfromtypecheck.dependsOnand add the lockfile toglobalDependencies.Within this hunk:
- "typecheck": { - "dependsOn": ["^build", "postinstall"] - }, + "typecheck": { + "dependsOn": ["^build"] + },Outside this hunk (illustrative JSON showing the updated list):
{ "globalDependencies": [ ".eslintrc.config.js", "tsconfig.json", "tsconfig.build.json", "scripts/**", "pnpm-lock.yaml" ] }
47-48: Keep test-dev non-cached to avoid stale results in local workflows.Dropping
cache: falsemeanstest-devwill now be cached by default. Tests often read from the clock, tmp dirs, or network; caching can mask failures while iterating locally.Apply:
"test-dev": { - "dependsOn": ["^build"] + "dependsOn": ["^build"], + "cache": false },If you intentionally want caching here for CI speed, consider a separate
test-citask left cached, and keeptest-devuncached for local fidelity.
53-54: Align test-start caching policy with intent; default caching may be undesirable.Similar to
test-dev, removingcache: falseenables caching. For E2E/startup-style tests, caching is typically risky.Apply:
"test-start": { - "dependsOn": ["^build", "build"] + "dependsOn": ["^build", "build"], + "cache": false }If the intent is to speed up CI, consider a dedicated cached CI task instead, and keep developer-facing or flaky-prone tasks uncached.
π Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
π‘ Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
π Files selected for processing (1)
turbo.json(1 hunks)
β° Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (19)
- GitHub Check: E2E-tests (next-minimal-starter)
- GitHub Check: E2E-tests (express-minimal)
- GitHub Check: E2E-tests (cloudflare-workers)
- GitHub Check: E2E-tests (.test/ssg)
- GitHub Check: E2E-tests (fastify-server)
- GitHub Check: e2e-legacy-node (next-prisma-todomvc, 20.x)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-todomvc, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 20.x)
- GitHub Check: e2e-legacy-node (next-prisma-starter, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-starter, 20.x)
- GitHub Check: E2E-tests (Deno) (deno-deploy)
- GitHub Check: Release using pkg.pr.new
- GitHub Check: E2E-tests (Bun) (bun, ubuntu-latest)
- GitHub Check: Test a monorepo using built declaration files
- GitHub Check: typecheck-www
- GitHub Check: test
- GitHub Check: typecheck
- GitHub Check: Lint and auto-fix
There was a problem hiding this comment.
Actionable comments posted: 0
π§Ή Nitpick comments (1)
.github/workflows/main.yml (1)
49-65: Optional hardening: restrict permissions and (optionally) gate by changed paths.
- Add least-privilege permissions to the job.
- If desired, skip this job when PRs donβt touch
www/**or configs it depends on.Apply:
typecheck-www: # only run on PRs if: github.event_name == 'pull_request' timeout-minutes: 10 + permissions: + contents: read env: TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} TURBO_TEAM: ${{ vars.TURBO_TEAM }} needs: [build] runs-on: ubuntu-latest steps:If you want path-based gating without changing triggers, consider
dorny/paths-filterto set an output and wrap thepnpm typecheck-wwwstep with anif:guard.
π Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
π‘ Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
π Files selected for processing (1)
.github/workflows/main.yml(1 hunks)
β° Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
- GitHub Check: test
- GitHub Check: typecheck
- GitHub Check: Lint and auto-fix
- GitHub Check: Analyze (typescript)
π Additional comments (4)
.github/workflows/main.yml (4)
47-48: Switch topnpm typecheck-packageslooks good.Matches the PRβs goal to parallelize package type checks and simplify CI.
49-65: Newtypecheck-wwwjob is clear and scoped.Gated to PRs, depends on build, and runs the expected script. Looks good.
49-65: Verified script wiring; no changes needed
Both rootpackage.jsondefinestypecheck-wwwandwww/package.jsondefinestypecheckas expected.
47-48: Typecheck scripts verified
Roottypecheck-packagesscript exists and every package underpackages/*defines atypecheckscript.
There was a problem hiding this comment.
Actionable comments posted: 1
π§Ή Nitpick comments (4)
.github/workflows/main.yml (4)
49-65: Gating www typecheck on build: clarify intent vs artifactsAdding
typecheck-wwwwithneeds: [build]gates sequencing but does not reuse build artifacts across runners. If the goal is just ordering, this is fine. If you intended to leverage build outputs, consider uploading/downloading artifacts or rely explicitly on Turbo remote cache being available.Example to make intent explicit (optional):
typecheck-www: if: github.event_name == 'pull_request' timeout-minutes: 10 env: TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} TURBO_TEAM: ${{ vars.TURBO_TEAM }} needs: [build] + # Note: needs only gates; no artifacts are shared. Turbo remote cache must be enabled to reuse work. runs-on: ubuntu-latest
150-152: Reduce Turbo invocations per exampleCombine build + typecheck for each example into one Turbo run to cut process startup overhead and better leverage the task graph/caching.
- - run: pnpm turbo --filter ./examples/${{ matrix.dir }} build - - run: pnpm turbo --filter ./examples/${{ matrix.dir }} typecheck + - run: pnpm turbo run build typecheck --filter ./examples/${{ matrix.dir }}
220-222: Same consolidation for Bun e2eMerge the two Turbo calls into one.
- - run: pnpm turbo --filter ./examples/${{ matrix.dir }} build - - run: pnpm turbo --filter ./examples/${{ matrix.dir }} typecheck + - run: pnpm turbo run build typecheck --filter ./examples/${{ matrix.dir }}
274-276: Same consolidation for legacy-node e2eMerge build + typecheck into a single Turbo run.
- - run: pnpm turbo --filter ./examples/${{ matrix.dir }} build - - run: pnpm turbo --filter ./examples/${{ matrix.dir }} typecheck + - run: pnpm turbo run build typecheck --filter ./examples/${{ matrix.dir }}
π Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
π‘ Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
π Files selected for processing (1)
.github/workflows/main.yml(4 hunks)
β° Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (17)
- GitHub Check: E2E-tests (next-prisma-todomvc)
- GitHub Check: E2E-tests (standalone-server)
- GitHub Check: E2E-tests (vercel-edge-runtime)
- GitHub Check: E2E-tests (nuxt)
- GitHub Check: E2E-tests (next-prisma-starter)
- GitHub Check: E2E-tests (minimal-react)
- GitHub Check: E2E-tests (.test/ssg)
- GitHub Check: E2E-tests (.experimental/next-app-dir)
- GitHub Check: E2E-tests (.test/diagnostics-big-router)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 20.x)
- GitHub Check: e2e-legacy-node (next-prisma-todomvc, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-websockets-starter, 18.x)
- GitHub Check: e2e-legacy-node (next-prisma-todomvc, 20.x)
- GitHub Check: e2e-legacy-node (next-prisma-starter, 20.x)
- GitHub Check: Release using pkg.pr.new
- GitHub Check: Test a monorepo using built declaration files
- GitHub Check: test
| - run: pnpm typecheck-packages | ||
|
|
There was a problem hiding this comment.
π‘ Verification agent
π§© Analysis chain
Confirm root script exists and matches intent
Switch to pnpm typecheck-packages looks good. Please confirm the root package.json defines this script and that it runs only package workspaces (not examples/www), since e2e jobs now typecheck examples separately.
Run:
π Script executed:
#!/bin/bash
set -euo pipefail
echo "Root has typecheck-packages script?"
rg -n '^ "typecheck-packages"\s*:' package.json
echo "www has its own typecheck script?"
rg -n '^ "typecheck"\s*:' www/package.json
echo "Packages define typecheck?"
fd package.json packages -x rg -n '^ "typecheck"\s*:'Length of output: 151
π Script executed:
#!/bin/bash
set -euo pipefail
echo "Root typecheck-packages script:"
python3 - << 'EOF'
import json
with open('package.json') as f:
data = json.load(f)
print(data.get('scripts', {}).get('typecheck-packages', 'not defined'))
EOF
echo "---"
echo "www typecheck script:"
if [ -f www/package.json ]; then
python3 - << 'EOF'
import json
with open('www/package.json') as f:
data = json.load(f)
print(data.get('scripts', {}).get('typecheck', 'not defined'))
EOF
else
echo "www/package.json not found"
fi
echo "---"
echo "Packages typecheck scripts:"
for pkgjson in packages/*/package.json; do
pkgdir=$(dirname "$pkgjson")
echo -n "$pkgdir: "
python3 -c "import json,sys; data=json.load(open(sys.argv[1])); print(data.get('scripts',{}).get('typecheck','not defined'))" "$pkgjson"
doneLength of output: 3047
Add missing typecheck script or adjust workspace filter
The root typecheck-packages script (pnpm run --parallel --filter=./packages/* typecheck) correctly targets only packages/* (not www), but packages/upgrade/package.json lacks a typecheck scriptβcausing the command to fail. Either define a typecheck script in packages/upgrade/package.json or narrow the filter to exclude upgrade.
π€ Prompt for AI Agents
.github/workflows/main.yml around lines 47 to 48: the CI step runs "pnpm
typecheck-packages" which expands to "pnpm run --parallel --filter=./packages/*
typecheck" but packages/upgrade/package.json has no "typecheck" script causing
the job to fail; fix by either adding a "typecheck" script to
packages/upgrade/package.json (e.g., pointing to tsc or the shared typecheck
command used by other packages) or tighten the workspace filter in the workflow
to exclude upgrade (for example filter by explicit packages or use negative
filter) so only packages that define "typecheck" are targeted.
|
This pull request has been locked because we are very unlikely to see comments on closed issues. If you think, this PR is still necessary, create a new one with the same branch. Thank you. |
Summary by CodeRabbit