Repository navigation
test(e2e): Add node-flue-send-to-sentry test app - #25550
RulaKhaled wants to merge 4 commits into
Conversation
A Flue app on Node that runs real OpenRouter turns and reads the gen_ai
spans back from a real Sentry project, with a `latest` variant. Also
checks in `node-flue` that each turn sits under the request that sent it,
and fixes its weather tool to read `({ data })`, the way Flue 2 passes
tool input.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ry apps Use the conventions search aliases and op constants, assert token usage, cost and the tool's arguments and result rather than presence alone, check that every chat span sits under the agent span, put the parent relationships into the wait conditions so the checks cannot run before the spans land, give the polls a 400s timeout, and report the response body when a turn is not admitted. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
357d873 to
c062e1f
Compare
|
bugbot run |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Want reviews to match your repository better? Bugbot Learning can learn team-specific rules from PR activity. A team admin can enable Learning in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit c062e1f. Configure here.
…span tests The model chooses the `get_weather` argument and may send `Berlin, Germany` as well as `Berlin`, so match on the city name rather than the exact string, as the Paris check already does. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
nicohrubec
left a comment
There was a problem hiding this comment.
might be worth doing one more agent round run to cut down the commentary a bit in a few places but else lgtm
| @@ -0,0 +1,110 @@ | |||
| import { expect, test } from '@playwright/test'; | |||
There was a problem hiding this comment.
l: the filename flue.test.ts doesn't really tell me what I'll find in here. I'd suggest renaming to tracing.test.ts or spans.test.ts for instance?
There was a problem hiding this comment.
i'd keep it, this is consistent with other e2e apps (it has spans, errors, dataloader, ..etc)
Keep only the reason for each comment, and drop the `'use agent'` explanation from the agent module, as asked in review. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
size-limit report 📦Compared: a2bca86 (PR test merge using develop at e9b9a3c) Against: d250a38 (develop) · base run #62866
|

An e2e app that uses the Flue integration the way a user does and sends the data to a real Sentry project, per #24753. Cloudflare already has one (
cloudflare-flue-send-to-sentry, #24816), so this covers Node.Stacked on #25549. Without that fix every turn after the first lands in the first request's trace, which these tests catch. This PR targets its branch and retargets to
developonce it merges.The app. A built Flue server, with
Sentry.initimported first and@sentry/node/importpreloaded, runs real tool-calling turns through OpenRouter. The router answers202before a turn runs, so the tests find each trace by thegen_ai.conversation.idFlue reports back, as the Cloudflare app does.@flue/runtimeis pinned to 2.0.5 likenode-flue, with a(latest)variant.hello.tsis a'use agent'module, so@flue/vitebinds its identity at build time, which the integration suite cannot reproduce.node-fluenow checks that each turn sits under the request that sent it. Its weather tool also reads({ data }), the way Flue 2 passes tool input, so it stops answering "sunny in undefined".Closes #24753
🤖 Generated with Claude Code