mirror of
https://github.com/KeygraphHQ/shannon.git
synced 2026-02-12 17:22:50 +00:00
chore: remove CLAUDE_CODE_MAX_OUTPUT_TOKENS env var handling
No longer needed with the new Claude Agent SDK version.
This commit is contained in:
@@ -220,9 +220,7 @@ export async function runClaudePrompt(
|
||||
const mcpServers = buildMcpServers(sourceDir, agentName);
|
||||
|
||||
// Build env vars to pass to SDK subprocesses
|
||||
const sdkEnv: Record<string, string> = {
|
||||
CLAUDE_CODE_MAX_OUTPUT_TOKENS: process.env.CLAUDE_CODE_MAX_OUTPUT_TOKENS || '64000',
|
||||
};
|
||||
const sdkEnv: Record<string, string> = {};
|
||||
if (process.env.ANTHROPIC_API_KEY) {
|
||||
sdkEnv.ANTHROPIC_API_KEY = process.env.ANTHROPIC_API_KEY;
|
||||
}
|
||||
|
||||
@@ -166,15 +166,6 @@ function handleStructuredError(
|
||||
false // Not retryable - needs code fix
|
||||
),
|
||||
};
|
||||
case 'max_output_tokens':
|
||||
return {
|
||||
detected: true,
|
||||
shouldThrow: new PentestError(
|
||||
`Max output tokens reached: ${content.slice(0, 100)}`,
|
||||
'billing',
|
||||
true // Retryable - may succeed with different content
|
||||
),
|
||||
};
|
||||
case 'unknown':
|
||||
default:
|
||||
return { detected: true };
|
||||
|
||||
@@ -73,7 +73,6 @@ export type SDKAssistantMessageError =
|
||||
| 'rate_limit'
|
||||
| 'invalid_request'
|
||||
| 'server_error'
|
||||
| 'max_output_tokens'
|
||||
| 'unknown';
|
||||
|
||||
export interface AssistantMessage {
|
||||
|
||||
Reference in New Issue
Block a user