Repository navigation
feat(deno): Add modulesIntegration - #26689
sentry-junior[bot] wants to merge 3 commits into
Conversation
size-limit report 📦Compared: d4a465a (PR test merge using develop at cee40e6) Against: cee40e6 (develop) · base run #67873 ✅ Baseline matches: this diff contains only this PR's changes.
|
|
One or more gzipped bundles increased by more than 500 bytes. If this increase is intentional, add the Accept Bundlesize Increase label to this PR to rerun and accept the check. |
08bb207 to
b4bcaf1
Compare
fbcde43 to
860014c
Compare
Optional E2E testsSome optional checks were not successful. They do not block the merge. 1 not successful, 26 successful. See the run.
Successful checks
|
8ddc24f to
1523597
Compare
e9f9ee8 to
dc440a7
Compare
3107010 to
043e3d8
Compare
1e067b7 to
489e0aa
Compare
ab0464f to
8bf5a66
Compare
9972bcc to
19de852
Compare
8bf5a66 to
9e9eba6
Compare
Reports the app's packages from deno.lock (jsr: and npm: specifiers) and from package.json/node_modules via the shared resolver. Files are only read when read permission is already granted, so it never prompts. Co-Authored-By: Francesco Gringl-Novy <2411343+mydea@users.noreply.github.com>
19de852 to
785802e
Compare
9e9eba6 to
44875b3
Compare
`@sentry/deno` now has `modulesIntegration`, so the two modules suites no longer need to be excluded. The tests that expect packages which were loaded but not declared in `package.json` stay Node and Bun only, because the Deno integration does not read the CommonJS module cache. Co-Authored-By: Francesco Gringl-Novy <2411343+mydea@users.noreply.github.com>
| const _modulesIntegration = (() => { | ||
| let modules: Record<string, string> | undefined; | ||
| return { | ||
| name: 'Modules', |
There was a problem hiding this comment.
| name: 'Modules', | |
| name: 'Modules' as const, |
Co-Authored-By: Francesco Gringl-Novy <2411343+mydea@users.noreply.github.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort 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 550c807. Configure here.
| // not readable | ||
| } | ||
| return undefined; | ||
| } |
There was a problem hiding this comment.
cwd is never found with scoped read permission
Low Severity
readFile() with no path also acts as the cwd getter. It calls Deno.permissions.querySync with path: undefined, which only reports granted when read access to everything is allowed. With a scoped permission such as --allow-read=., cwd is always undefined. When the main module isn't a file: URL, nothing is collected even though the files can be read.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 550c807. Configure here.


What
@sentry/denonow includesmodulesIntegrationby default. It reports exact versions ofjsr:andnpm:packages from the nearestdeno.lock(lockfile versions 3 to 5). For apps with apackage.json, it also reports those dependencies, using the shared resolver from #26637.Why
Deno had no modules integration, so its events had no package versions. The integration only reads files when read permission is already granted, checked with
Deno.permissions.querySync. So it never prompts, and it does nothing without--allow-read. Withoutnode_modules, the resolver only knows the ranges declared inpackage.json, so the exact versions indeno.locktake precedence.packages/deno/test/fixtures/modules/deno.lockis force-added becausedeno.lockis gitignored. The test runs the fixture with--no-lockso Deno doesn't rewrite it.via @mydea.
--
View Session [Sentry]