Skip to content

handle optional parentheses in chrome's regex#46

Open
mattzucker wants to merge 1 commit intonovocaine:masterfrom
mattzucker:bugfix/optional-parentheses
Open

handle optional parentheses in chrome's regex#46
mattzucker wants to merge 1 commit intonovocaine:masterfrom
mattzucker:bugfix/optional-parentheses

Conversation

@mattzucker
Copy link

@mattzucker mattzucker commented Jun 3, 2025

This pull request fixes the bug identified here #45
The regex for chrome works whether the line in the stack trace has parentheses around the file URL or not. Instead of relying on the parentheses, the regex now expects there to be a space in between " at " and the file URL. This should be a more robust approach to match the stack trace.

Examples used for testing

    at http://localhost:8080/main.26e4650d3cdd95bc281a.js:87876:62

is mapped to

    at (unknown) (webpack://project/src/main/webapp/test.js:20:3)

Previous mapping continues to work, such as

    at Object.error (http://localhost:8080/main.26e4650d3cdd95bc281a.js:87864:76)

is mapped to

    at Object.error (webpack://project/src/main/webapp/test.js:51:17)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant