style: 完成所有文件的lint

This commit is contained in:
claude-code-best
2026-05-01 21:39:30 +08:00
parent d136872cc9
commit 6182015005
1333 changed files with 68255 additions and 77882 deletions

View File

@@ -267,7 +267,9 @@ export function truncateHeadForPTLRetry(
let acc = 0
dropCount = 0
for (const g of groups) {
acc += roughTokenCountEstimationForMessages(g as Parameters<typeof roughTokenCountEstimationForMessages>[0])
acc += roughTokenCountEstimationForMessages(
g as Parameters<typeof roughTokenCountEstimationForMessages>[0],
)
dropCount++
if (acc >= tokenGap) break
}
@@ -762,7 +764,7 @@ export async function compactConversation(
context.setStreamMode?.('requesting')
context.setResponseLength?.(() => 0)
context.onCompactProgress?.({ type: 'compact_end' })
context.setSDKStatus?.("" as SDKStatus)
context.setSDKStatus?.('' as SDKStatus)
}
}
@@ -1105,7 +1107,7 @@ export async function partialCompactConversation(
context.setStreamMode?.('requesting')
context.setResponseLength?.(() => 0)
context.onCompactProgress?.({ type: 'compact_end' })
context.setSDKStatus?.("" as SDKStatus)
context.setSDKStatus?.('' as SDKStatus)
}
}
@@ -1333,8 +1335,18 @@ async function streamCompactSummary({
let next = await streamIter.next()
while (!next.done) {
const event = next.value as StreamEvent | AssistantMessage | SystemAPIErrorMessage
const streamEvent = event as { type: string; event: { type: string; content_block: { type: string }; delta: { type: string; text: string } } }
const event = next.value as
| StreamEvent
| AssistantMessage
| SystemAPIErrorMessage
const streamEvent = event as {
type: string
event: {
type: string
content_block: { type: string }
delta: { type: string; text: string }
}
}
if (
!hasStartedStreaming &&