Skip to content

Commit 5ce395e

Browse files
committed
lint yelling
1 parent 4603f87 commit 5ce395e

File tree

5 files changed

+13
-21
lines changed

5 files changed

+13
-21
lines changed

dev-packages/node-integration-tests/suites/tracing/anthropic/instrument-with-pii.mjs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,5 @@ Sentry.init({
88
tracesSampleRate: 1.0,
99
sendDefaultPii: true,
1010
transport: loggingTransport,
11-
integrations: [
12-
Sentry.anthropicAIIntegration(),
13-
nodeContextIntegration(),
14-
],
11+
integrations: [Sentry.anthropicAIIntegration(), nodeContextIntegration()],
1512
});

dev-packages/node-integration-tests/suites/tracing/anthropic/instrument.mjs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,5 @@ Sentry.init({
99
sendDefaultPii: false,
1010
transport: loggingTransport,
1111
// Force include the integration
12-
integrations: [
13-
Sentry.anthropicAIIntegration(),
14-
nodeContextIntegration(),
15-
],
12+
integrations: [Sentry.anthropicAIIntegration(), nodeContextIntegration()],
1613
});

dev-packages/node-integration-tests/suites/tracing/anthropic/scenario-stream-tools.mjs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,11 @@ function createMockStreamEvents(model = 'claude-3-haiku-20240307') {
2121
yield { type: 'content_block_delta', delta: { text: 'Starting tool...' } };
2222

2323
// tool_use streamed via partial json
24-
yield { type: 'content_block_start', index: 0, content_block: { type: 'tool_use', id: 'tool_weather_2', name: 'weather' } };
24+
yield {
25+
type: 'content_block_start',
26+
index: 0,
27+
content_block: { type: 'tool_use', id: 'tool_weather_2', name: 'weather' },
28+
};
2529
yield { type: 'content_block_delta', index: 0, delta: { partial_json: '{"city":' } };
2630
yield { type: 'content_block_delta', index: 0, delta: { partial_json: '"Paris"}' } };
2731
yield { type: 'content_block_stop', index: 0 };

dev-packages/node-integration-tests/suites/tracing/anthropic/scenario-stream.mjs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,5 +101,3 @@ async function run() {
101101
}
102102

103103
run();
104-
105-

dev-packages/node-integration-tests/suites/tracing/anthropic/scenario.mjs

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ class MockAnthropic {
88
// Create messages object with create and countTokens methods
99
this.messages = {
1010
create: this._messagesCreate.bind(this),
11-
countTokens: this._messagesCountTokens.bind(this)
11+
countTokens: this._messagesCountTokens.bind(this),
1212
};
1313

1414
this.models = {
@@ -56,8 +56,8 @@ class MockAnthropic {
5656

5757
// For countTokens, just return input_tokens
5858
return {
59-
input_tokens: 15
60-
}
59+
input_tokens: 15,
60+
};
6161
}
6262

6363
async _modelsRetrieve(modelId) {
@@ -69,7 +69,7 @@ class MockAnthropic {
6969
id: modelId,
7070
name: modelId,
7171
created_at: 1715145600,
72-
model: modelId, // Add model field to match the check in addResponseAttributes
72+
model: modelId, // Add model field to match the check in addResponseAttributes
7373
};
7474
}
7575
}
@@ -86,9 +86,7 @@ async function run() {
8686
await client.messages.create({
8787
model: 'claude-3-haiku-20240307',
8888
system: 'You are a helpful assistant.',
89-
messages: [
90-
{ role: 'user', content: 'What is the capital of France?' },
91-
],
89+
messages: [{ role: 'user', content: 'What is the capital of France?' }],
9290
temperature: 0.7,
9391
max_tokens: 100,
9492
});
@@ -106,9 +104,7 @@ async function run() {
106104
// Third test: count tokens with cached tokens
107105
await client.messages.countTokens({
108106
model: 'claude-3-haiku-20240307',
109-
messages: [
110-
{ role: 'user', content: 'What is the capital of France?' },
111-
],
107+
messages: [{ role: 'user', content: 'What is the capital of France?' }],
112108
});
113109

114110
// Fourth test: models.retrieve

0 commit comments

Comments
 (0)