Skip to content

Commit 0adbf09

Browse files
committed
fix some tests
1 parent ce44b0b commit 0adbf09

File tree

2 files changed

+2
-1
lines changed
  • dev-packages/node-integration-tests/suites/tracing/anthropic
  • packages/core/src/utils/anthropic-ai

2 files changed

+2
-1
lines changed

dev-packages/node-integration-tests/suites/tracing/anthropic/test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,7 @@ describe('Anthropic integration', () => {
237237
'gen_ai.usage.input_tokens': 10,
238238
'gen_ai.usage.output_tokens': 15,
239239
'gen_ai.usage.total_tokens': 25,
240+
'gen_ai.response.finish_reasons': '["end_turn"]',
240241
}),
241242
}),
242243
// messages.stream

packages/core/src/utils/anthropic-ai/streaming.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ function isErrorEvent(
7171
}
7272

7373
if (recordOutputs && event.type === 'content_block_delta') {
74-
const text = event.delta?.text ?? '';
74+
const text = event.delta?.text;
7575
if (text) state.responseTexts.push(text);
7676
}
7777
}

0 commit comments

Comments
 (0)