Skip to content
This repository was archived by the owner on Apr 19, 2024. It is now read-only.

rewriteLocalizeCalls is messing up sourcemappings in vscode-node-debug #14

@roblourens

Description

@roblourens

In nodeDebug.ts, this comment exists at line 431:

/*
this._node.on('beforeCompile', (event: NodeV8Event) => {
	this.outLine(`beforeCompile ${this._scriptToPath(event.body.script)}`);
});

this._node.on('afterCompile', (event: NodeV8Event) => {
	this.outLine(`afterCompile ${this._scriptToPath(event.body.script)}`);
});
*/

After this comment, the sourcemappings are incorrect, making it very hard to debug. You can see this by building and using the sourcemap visualizer: https://sokra.github.io/source-map-visualization. There shouldn't be several mappings on these lines, on individual letters, etc:
image

It looks like the empty line between those two blocks is removed, and the subsequent mappings are all off by a line. Looking at the code, I have no clue why that would happen.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugIssue identified by VS Code Team member as probable bug

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions