Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(runtime): error stack traces missing column numbers #17876

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

DonIsaac
Copy link
Contributor

@DonIsaac DonIsaac commented Mar 3, 2025

What does this PR do?

Fixes callsite printing in stack traces to always print a column number whenever a line number is printed. It now defaults to 1.

Some existing libraries will parse stack traces to look for a line/column number. In node, column numbers default to 1 and are always present when line numbers are. This PR fixes this incompatibility.

@DonIsaac DonIsaac added the node.js Compatibility with Node.js APIs label Mar 3, 2025
@DonIsaac DonIsaac requested a review from dylan-conway March 3, 2025 19:53
@robobun
Copy link

robobun commented Mar 3, 2025

Updated 11:53 AM PT - Mar 3rd, 2025

@DonIsaac, your commit 4af10c4 is building: #12591

Copy link
Collaborator

@Jarred-Sumner Jarred-Sumner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will need to be updated in two places. This place is when you have Error.prepareStackTrace defined and return the CallSite objects.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
node.js Compatibility with Node.js APIs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants