Date: 2026-03-11
Status: ⚠️ Merge blocked — CI typecheck errors pending resolution
/dashboard/products/[id]/ai-cost showing credit spend broken down by agent type, with horizontal bar charts and token countsaiCost tRPC router (getMonthlySummary, getMonthlyTrend, getCrossProjectSummary, setBudgetLimit, getRecentTransactions) joining creditTransactions → agentJobs → pipelineRunsThe platform deducts credits per agent run but previously had no UI to show where they went. This closes that gap — teams can now see exactly which agents are consuming budget on which project and set limits before costs run away.
billingSettings under key ai_budget_monthly_limitforce-dynamic for auth safetyplatform-billing, agent-coordination, mcp, chat, rollback, portfolio) referenced in root.tsThe CI check failed with TypeScript errors in src/lib/trpc/root.ts — several imported router modules cannot be found. These are pre-existing issues in the repo that are blocking the merge. Here's the full picture:
PR #137 — Per-Project AI Cost & Token Usage Dashboard with Budget Alerts — could not be merged because the TypeScript typecheck CI job failed with the following errors in src/lib/trpc/root.ts:
| Error | File |
|---|---|
TS2307: Cannot find module '@/lib/routers/platform-billing' | src/lib/trpc/root.ts:14 |
TS2307: Cannot find module '@/lib/routers/agent-coordination' | src/lib/trpc/root.ts:45 |
TS2307: Cannot find module '@/lib/routers/mcp' | src/lib/trpc/root.ts:46 |
TS2307: Cannot find module '@/lib/routers/chat' | src/lib/trpc/root.ts:47 |
TS2307: Cannot find module '@/lib/routers/rollback' | src/lib/trpc/root.ts:48 |
TS2307: Cannot find module '@/lib/routers/portfolio' | src/lib/trpc/root.ts:49 |
These are missing router files referenced in root.ts — several of them were imported by this PR's changes to root.ts (notably platform-billing), and others appear to be pre-existing stubs or other in-flight PRs that haven't landed yet. Until all referenced modules exist and typecheck passes, the merge is blocked.
platform-billing, agent-coordination, mcp, chat, rollback, portfolio) so TypeScript can resolve the imports, orroot.ts until those PRs land, orWould you like me to create stub router files to unblock the typecheck and retry the merge?