Skip to content

Commit ecaee2e

Browse files
authored
Merge pull request #1940 from braintrustdata/prepare-release/0a2e9115c308
chore: Prepare for release (0a2e911)
2 parents a6d62c4 + a8b1850 commit ecaee2e

168 files changed

Lines changed: 12661 additions & 1223 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.agents/skills/e2e-tests/SKILL.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ Try not to use specific test narrowing commands unless hunting down a very nasty
4545
- Keep reusable logic in `e2e/helpers/`. Keep one-off fixtures and scenario-specific files inside the scenario directory.
4646
- Snapshot stable contracts, not raw noise. Use `normalizeForSnapshot(...)` before inline snapshots and `formatJsonFileSnapshot(...)` plus file snapshots for larger payloads or version matrices.
4747
- When a scenario family already has `assertions.ts`, keep version- or provider-specific test setup in `scenario.test.ts` and reuse the shared assertions file.
48+
- Keep the CI e2e summary up to date. If a scenario version matrix or `variantKey` changes, update `e2e/config/pr-comment-scenarios.json` in the same change and follow the established pattern used by other versioned scenarios: one summary row per version, not separate wrapped/auto rows unless that pattern already exists for the scenario family.
4849
- Run new or updated scenarios three times in a row before considering snapshots stable.
4950

5051
## Scenario Patterns

.env.example

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@ BRAINTRUST_API_KEY=
22
OPENAI_API_KEY=
33
ANTHROPIC_API_KEY=
44
GEMINI_API_KEY=
5+
CURSOR_API_KEY=
56
OPENROUTER_API_KEY=
67
MISTRAL_API_KEY=
78
HUGGINGFACE_API_KEY=
89
COHERE_API_KEY=
10+
GROQ_API_KEY=

.github/workflows/checks.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -459,7 +459,6 @@ jobs:
459459
- js-test
460460
- js-build
461461
- e2e-hermetic
462-
- js-api-compatibility
463462
- js-smoke-discover
464463
- js-smoke-test
465464
- temporal-js
@@ -492,7 +491,6 @@ jobs:
492491
check_result "js-test" "${{ needs.js-test.result }}"
493492
check_result "js-build" "${{ needs.js-build.result }}"
494493
check_result "e2e-hermetic" "${{ needs.e2e-hermetic.result }}"
495-
check_result "js-api-compatibility" "${{ needs.js-api-compatibility.result }}"
496494
check_result "js-smoke-discover" "${{ needs.js-smoke-discover.result }}"
497495
check_result "js-smoke-test" "${{ needs.js-smoke-test.result }}"
498496
check_result "temporal-js" "${{ needs.temporal-js.result }}"

.github/workflows/e2e-canary.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,8 @@ jobs:
3535
BRAINTRUST_E2E_PROJECT_NAME: ${{ vars.BRAINTRUST_E2E_PROJECT_NAME }}
3636
GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
3737
COHERE_API_KEY: ${{ secrets.COHERE_API_KEY }}
38+
CURSOR_API_KEY: ${{ secrets.CURSOR_API_KEY }}
39+
GROQ_API_KEY: ${{ secrets.GROQ_API_KEY }}
3840
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
3941
OPENROUTER_API_KEY: ${{ secrets.OPENROUTER_API_KEY }}
4042
MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }}

.github/workflows/integration-tests.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ jobs:
2929
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
3030
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
3131
GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
32+
CURSOR_API_KEY: ${{ secrets.CURSOR_API_KEY }}
3233
OPENROUTER_API_KEY: ${{ secrets.OPENROUTER_API_KEY }}
3334
MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }}
3435
HUGGINGFACE_API_KEY: ${{ secrets.HUGGINGFACE_API_KEY }}
@@ -58,6 +59,8 @@ jobs:
5859
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
5960
GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
6061
COHERE_API_KEY: ${{ secrets.COHERE_API_KEY }}
62+
CURSOR_API_KEY: ${{ secrets.CURSOR_API_KEY }}
63+
GROQ_API_KEY: ${{ secrets.GROQ_API_KEY }}
6164
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
6265
OPENROUTER_API_KEY: ${{ secrets.OPENROUTER_API_KEY }}
6366
MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }}
@@ -109,6 +112,8 @@ jobs:
109112
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
110113
GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
111114
COHERE_API_KEY: ${{ secrets.COHERE_API_KEY }}
115+
CURSOR_API_KEY: ${{ secrets.CURSOR_API_KEY }}
116+
GROQ_API_KEY: ${{ secrets.GROQ_API_KEY }}
112117
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
113118
OPENROUTER_API_KEY: ${{ secrets.OPENROUTER_API_KEY }}
114119
MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }}

.github/workflows/prepare-js-release.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,8 @@ jobs:
5454
echo "release_branch=$release_branch"
5555
} >> "$GITHUB_OUTPUT"
5656
- name: Run changeset version
57+
env:
58+
GITHUB_TOKEN: ${{ github.token }}
5759
run: pnpm exec changeset version
5860
- name: Create release commit
5961
run: |

e2e/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,10 +115,12 @@ Non-hermetic scenarios require provider credentials in addition to the mock Brai
115115
- `OPENAI_API_KEY`
116116
- `ANTHROPIC_API_KEY`
117117
- `GEMINI_API_KEY` or `GOOGLE_API_KEY`
118+
- `CURSOR_API_KEY`
118119
- `OPENROUTER_API_KEY`
119120
- `MISTRAL_API_KEY`
120121
- `HUGGINGFACE_API_KEY`
121122
- `COHERE_API_KEY`
123+
- `GROQ_API_KEY`
122124

123125
`claude-agent-sdk-instrumentation` also uses `ANTHROPIC_API_KEY`, because it runs the real Claude Agent SDK against Anthropic in the same style as the existing live Anthropic wrapper coverage.
124126

e2e/config/pr-comment-scenarios.json

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,10 @@
2626
"scenarioDirName": "google-adk-instrumentation",
2727
"label": "Google ADK Instrumentation",
2828
"metadataScenario": "google-adk-instrumentation",
29-
"variants": [{ "variantKey": "google-adk-v061", "label": "v0.6.1" }]
29+
"variants": [
30+
{ "variantKey": "google-adk-v061", "label": "v0.6.1" },
31+
{ "variantKey": "google-adk-v1000", "label": "v1.0.0" }
32+
]
3033
},
3134
{
3235
"scenarioDirName": "google-genai-instrumentation",
@@ -39,6 +42,15 @@
3942
{ "variantKey": "google-genai-v1460", "label": "v1.46.0" }
4043
]
4144
},
45+
{
46+
"scenarioDirName": "groq-instrumentation",
47+
"label": "Groq Instrumentation",
48+
"metadataScenario": "groq-instrumentation",
49+
"variants": [
50+
{ "variantKey": "groq-v1-wrapped", "label": "Wrapped" },
51+
{ "variantKey": "groq-v1-auto", "label": "Auto-hook" }
52+
]
53+
},
4254
{
4355
"scenarioDirName": "huggingface-instrumentation",
4456
"label": "HuggingFace Instrumentation",
@@ -121,5 +133,11 @@
121133
"label": "v0.2.81"
122134
}
123135
]
136+
},
137+
{
138+
"scenarioDirName": "cursor-sdk-instrumentation",
139+
"label": "Cursor SDK Instrumentation",
140+
"metadataScenario": "cursor-sdk-instrumentation",
141+
"variants": [{ "variantKey": "cursor-sdk-v1", "label": "v1" }]
124142
}
125143
]

e2e/helpers/scenario-installer.ts

Lines changed: 6 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,11 @@ const INSTALL_SECRET_ENV_VARS = [
2222
"ANTHROPIC_API_KEY",
2323
"BRAINTRUST_API_KEY",
2424
"COHERE_API_KEY",
25+
"CURSOR_API_KEY",
2526
"GEMINI_API_KEY",
2627
"GITHUB_TOKEN",
2728
"GH_TOKEN",
29+
"GROQ_API_KEY",
2830
"HUGGINGFACE_API_KEY",
2931
"OPENAI_API_KEY",
3032
"OPENROUTER_API_KEY",
@@ -36,10 +38,9 @@ let cleanupRegistered = false;
3638

3739
type CanaryDependencyRule = {
3840
packageName: string;
39-
query: string;
41+
version: string;
4042
};
4143

42-
const canaryVersionCache = new Map<string, string>();
4344
const HELPERS_DIR = path.dirname(fileURLToPath(import.meta.url));
4445
const E2E_ROOT = path.resolve(HELPERS_DIR, "..");
4546

@@ -154,32 +155,6 @@ function packageSpecifier(
154155
: `npm:${packageName}@${version}`;
155156
}
156157

157-
async function resolveCanaryVersion(
158-
rule: CanaryDependencyRule,
159-
): Promise<string> {
160-
const cacheKey = rule.query;
161-
const cached = canaryVersionCache.get(cacheKey);
162-
if (cached) {
163-
return cached;
164-
}
165-
166-
const output = await spawnOrThrow(
167-
PNPM_COMMAND,
168-
["view", rule.query, "version", "--json"],
169-
process.cwd(),
170-
installEnv(),
171-
);
172-
const parsed = JSON.parse(output) as string | string[];
173-
const version = Array.isArray(parsed) ? parsed.at(-1) : parsed;
174-
175-
if (typeof version !== "string") {
176-
throw new Error(`Could not resolve canary version for ${rule.query}`);
177-
}
178-
179-
canaryVersionCache.set(cacheKey, version);
180-
return version;
181-
}
182-
183158
function parseCanaryDependencyRule(
184159
dependencyName: string,
185160
rawRule: string,
@@ -194,7 +169,7 @@ function parseCanaryDependencyRule(
194169
if (rawRule === "latest") {
195170
return {
196171
packageName: dependencyName,
197-
query: dependencyName,
172+
version: "latest",
198173
};
199174
}
200175

@@ -207,7 +182,7 @@ function parseCanaryDependencyRule(
207182

208183
return {
209184
packageName: rawRule.slice(0, versionSeparator),
210-
query: rawRule,
185+
version: rawRule.slice(versionSeparator + 1),
211186
};
212187
}
213188

@@ -229,11 +204,10 @@ async function rewriteManifestForCanary(scenarioDir: string): Promise<void> {
229204
rawRule,
230205
scenarioDir,
231206
);
232-
const version = await resolveCanaryVersion(rule);
233207
dependencies[dependencyName] = packageSpecifier(
234208
dependencyName,
235209
rule.packageName,
236-
version,
210+
rule.version,
237211
);
238212
updated = true;
239213
}

e2e/scenarios/ai-sdk-instrumentation/scenario.impl.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ async function runAISDKInstrumentationScenario(
143143
) {
144144
const instrumentedAI = decorateAI ? decorateAI(options.ai) : options.ai;
145145
const openaiModel = options.openai("gpt-4o-mini-2024-07-18");
146-
const anthropicModel = options.anthropic?.("claude-3-haiku-20240307");
146+
const anthropicModel = options.anthropic?.("claude-haiku-4-5");
147147
const openaiEmbeddingModel = options.openai.textEmbeddingModel(
148148
"text-embedding-3-small",
149149
);

0 commit comments

Comments
 (0)