You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CLAUDE.md
+10Lines changed: 10 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,6 +18,16 @@ pnpm run dev --filter webapp # Run webapp (http://localhost:3030)
18
18
pnpm run dev --filter trigger.dev --filter "@trigger.dev/*"# Watch CLI and packages
19
19
```
20
20
21
+
### Verifying Webapp Changes
22
+
23
+
**Never run `pnpm run build --filter webapp` to verify changes.** Building proves almost nothing about correctness. Instead, run typecheck from the repo root:
24
+
25
+
```bash
26
+
pnpm run typecheck --filter webapp # ~1-2 minutes
27
+
```
28
+
29
+
Only run typecheck after major changes (new files, significant refactors, schema changes). For small edits, trust the types and let CI catch issues.
30
+
21
31
## Testing
22
32
23
33
We use vitest exclusively. **Never mock anything** - use testcontainers instead.
Copy file name to clipboardExpand all lines: apps/webapp/CLAUDE.md
+10Lines changed: 10 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,6 +2,16 @@
2
2
3
3
Remix 2.1.0 app serving as the main API, dashboard, and orchestration engine. Uses an Express server (`server.ts`).
4
4
5
+
## Verifying Changes
6
+
7
+
**Never run `pnpm run build --filter webapp` to verify changes.** Building proves almost nothing about correctness. Instead, run typecheck from the repo root:
8
+
9
+
```bash
10
+
pnpm run typecheck --filter webapp # ~1-2 minutes
11
+
```
12
+
13
+
Only run typecheck after major changes (new files, significant refactors, schema changes). For small edits, trust the types and let CI catch issues.
Copy file name to clipboardExpand all lines: apps/webapp/app/presenters/v3/PromptPresenter.server.ts
+46Lines changed: 46 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -365,6 +365,52 @@ export class PromptPresenter extends BasePresenter {
365
365
}
366
366
returnrows.map((r)=>r.prompt_slug);
367
367
}
368
+
369
+
asyncgetDistinctOperations(
370
+
organizationId: string,
371
+
projectId: string,
372
+
environmentId: string
373
+
): Promise<string[]>{
374
+
constqueryFn=this.clickhouse.reader.query({
375
+
name: "getDistinctOperations",
376
+
query: `SELECT DISTINCT operation_id FROM trigger_dev.llm_metrics_v1 WHERE organization_id = {organizationId: String} AND project_id = {projectId: String} AND environment_id = {environmentId: String} AND operation_id != '' ORDER BY operation_id`,
query: `SELECT DISTINCT gen_ai_system FROM trigger_dev.llm_metrics_v1 WHERE organization_id = {organizationId: String} AND project_id = {projectId: String} AND environment_id = {environmentId: String} AND gen_ai_system != '' ORDER BY gen_ai_system`,
Copy file name to clipboardExpand all lines: apps/webapp/app/routes/_app.orgs.$organizationSlug.projects.$projectParam.env.$envParam.dashboards.$dashboardKey/route.tsx
query: `SELECT DISTINCT operation_id FROM trigger_dev.llm_metrics_v1 WHERE organization_id = {organizationId: String} AND project_id = {projectId: String} AND environment_id = {environmentId: String} AND operation_id != '' ORDER BY operation_id`,
116
-
params: z.object({
117
-
organizationId: z.string(),
118
-
projectId: z.string(),
119
-
environmentId: z.string(),
120
-
}),
121
-
schema: z.object({operation_id: z.string()}),
122
-
});
123
-
const[error,rows]=awaitqueryFn({
124
-
organizationId: project.organizationId,
125
-
projectId: project.id,
126
-
environmentId: environment.id,
127
-
});
128
-
if(!error){
129
-
possibleOperations=rows.map((r)=>r.operation_id);
130
-
}
131
-
}
132
-
133
-
letpossibleProviders: string[]=[];
134
-
if(filters.includes("providers")){
135
-
constqueryFn=clickhouseClient.reader.query({
136
-
name: "getDistinctProviders",
137
-
query: `SELECT DISTINCT gen_ai_system FROM trigger_dev.llm_metrics_v1 WHERE organization_id = {organizationId: String} AND project_id = {projectId: String} AND environment_id = {environmentId: String} AND gen_ai_system != '' ORDER BY gen_ai_system`,
0 commit comments