Skip to content

determineSourceMapPathFromBundle wat not upload .map file when sourceMappingURL do not start with 'file' #423

@zalatmza

Description

@zalatmza

Environment

2.8.0

Steps to Reproduce

I set sourceMappingURL like //# sourceMappingURL=http://www.site.com/path/xxx.index.js.map, but the xxx.index.js.map was not uploaded.

// xxx.index.js

xxxxxx
//# sourceMappingURL=http://www.site.com/path/xxx.index.js.map

Source Map Upload Report
  Minified Scripts
    ~/90f45aeb-c3f4-4ecb-87ed-e243500ec3b0-0.js (sourcemap at http://www.site.com/path/xxx.index.js.map, debug id 90f45aeb-c3f4-4ecb-87ed-e243500ec3b0)
[sentry-vite-plugin] Info: Successfully uploaded source maps to Sentry

Failed to find file locally when URL is not supported

Expected Result

Source Map Upload Report
  Minified Scripts
    ~/cfa8805b-8003-40d5-88e7-5a1ab1ddae10-0.js(sourcemap at http://www.site.com/path/xxx.index.js.map, debug id 90f45aeb-c3f4-4ecb-87ed-e243500ec3b0)
  Source Maps
    ~/cfa8805b-8003-40d5-88e7-5a1ab1ddae10-0.js.map (debug id cfa8805b-8003-40d5-88e7-5a1ab1ddae10)
[sentry-vite-plugin] Info: Successfully uploaded source maps to Sentry

Actual Result

Source Map Upload Report
  Minified Scripts
    ~/90f45aeb-c3f4-4ecb-87ed-e243500ec3b0-0.js (sourcemap at http://www.site.com/path/xxx.index.js.map, debug id 90f45aeb-c3f4-4ecb-87ed-e243500ec3b0)
[sentry-vite-plugin] Info: Successfully uploaded source maps to Sentry

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels
    No fields configured for issues without a type.

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions