Fix repo typecheck failures
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
"dev:tsx": "NODE_ENV=development tsx watch --ignore '**/*.timestamp-*' src/server/index.ts",
|
||||
"build": "tsc -p tsconfig.server.json",
|
||||
"start": "NODE_ENV=production node dist/server/index.js",
|
||||
"typecheck": "tsc -p tsconfig.server.json --noEmit",
|
||||
"typecheck": "tsc -p tsconfig.server.typecheck.json --noEmit",
|
||||
"test": "vitest run",
|
||||
"test:watch": "vitest",
|
||||
"test:ui": "vitest --ui",
|
||||
|
||||
@@ -4,7 +4,12 @@ import os from "node:os";
|
||||
import path from "node:path";
|
||||
|
||||
import { ClaudeAgentClient, convertClaudeHistoryEntry } from "./claude-agent.js";
|
||||
import { hydrateStreamState, type StreamItem, type ToolCallItem, type AgentToolCallData } from "../../../../../app/src/types/stream.js";
|
||||
import {
|
||||
hydrateStreamState,
|
||||
type StreamItem,
|
||||
type AgentToolCallData,
|
||||
isAgentToolCallItem,
|
||||
} from "../../../../../app/src/types/stream.js";
|
||||
import type { AgentStreamEventPayload } from "../../messages.js";
|
||||
import type { AgentProvider, AgentSessionConfig, AgentStreamEvent, AgentTimelineItem } from "../agent-sdk-types.js";
|
||||
|
||||
@@ -596,15 +601,10 @@ function stateIncludesUserMessage(state: StreamItem[], marker: string): boolean
|
||||
}
|
||||
|
||||
function extractAgentToolSnapshots(state: StreamItem[]): ToolSnapshot[] {
|
||||
return state
|
||||
.filter(
|
||||
(item): item is ToolCallItem =>
|
||||
item.kind === "tool_call" && item.payload.source === "agent"
|
||||
)
|
||||
.map((item) => ({
|
||||
key: buildToolSnapshotKey(item.payload.data, item.id),
|
||||
data: item.payload.data,
|
||||
}));
|
||||
return state.filter(isAgentToolCallItem).map((item) => ({
|
||||
key: buildToolSnapshotKey(item.payload.data, item.id),
|
||||
data: item.payload.data,
|
||||
}));
|
||||
}
|
||||
|
||||
function buildToolSnapshotKey(data: AgentToolCallData, fallbackId: string): string {
|
||||
|
||||
@@ -4,6 +4,10 @@
|
||||
"module": "NodeNext",
|
||||
"moduleResolution": "NodeNext",
|
||||
"lib": ["ES2020"],
|
||||
"baseUrl": "./src",
|
||||
"paths": {
|
||||
"@server/*": ["./*"]
|
||||
},
|
||||
"skipLibCheck": true,
|
||||
"resolveJsonModule": true,
|
||||
"isolatedModules": true,
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"extends": "./tsconfig.server.json",
|
||||
"compilerOptions": {
|
||||
"rootDir": "../../"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user