ref(node): Streamline dataloader instrumentation#21475
Conversation
f1ab607 to
070c3c0
Compare
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.
Reviewed by Cursor Bugbot for commit 070c3c0. Configure here.
| await runner.makeRequest('get', '/load'); | ||
| await runner.makeRequest('get', '/load-many'); | ||
| await runner.makeRequest('get', '/cache-ops'); | ||
| await runner.makeRequest('get', '/named'); |
There was a problem hiding this comment.
Chained expects assume envelope order
Medium Severity
The test chains four .expect({ transaction: … }) callbacks, but the integration runner matches incoming envelopes with expectedEnvelopes.shift(), so the first callback always runs on the first transaction received—not necessarily GET /load. Four back-to-back HTTP requests can emit transactions in a different order than the expects, causing flaky failures when the wrong callback validates the wrong route.
Triggered by project rule: PR Review Guidelines for Cursor Bot
Reviewed by Cursor Bugbot for commit 070c3c0. Configure here.
There was a problem hiding this comment.
this should not be possible to flush in a different order
946b207 to
837e1db
Compare


This streamlines the vendored dataloader instrumentation:
Sentry.startSpaninstead of tracer APIson('spanStart')directly into the instrumentationThis is overall much simpler, as we use the built-in error handling etc. from Sentry.startSpan.
Closes #20725