Giter Club home page Giter Club logo

Comments (6)

roblourens avatar roblourens commented on June 6, 2024 1

Can you use sourceMapPathOverrides to add a mapping from ...foo:bar... to ...foo-bar... or however it is?

from vscode-node-debug.

mrsimpson avatar mrsimpson commented on June 6, 2024 1

Wohoo! You really prepared for a lot of generated-framework-source sh*t features ๐ŸŽ‰

I added two mappings and it works like a charm:

"sourceMapPathOverrides": {
	"meteor://๐Ÿ’ปapp/packages/assistify:*": "${workspaceFolder}/packages/assistify-*",
	"meteor://๐Ÿ’ปapp/packages/rocketchat:*": "${workspaceFolder}/packages/rocketchat-*"
}

Thanks a ton, saved me a lot of frustration!

Oliver

P.s.: I'd be delighted if you supported regex in addition to glob with parameters which can be used at the replacing side.

from vscode-node-debug.

auchenberg avatar auchenberg commented on June 6, 2024

What version of Meteor are you using? We had some issues, which were resolved in 1.6, that triggers me ud to write this guide: https://github.com/Microsoft/vscode-recipes/tree/master/meteor

from vscode-node-debug.

mrsimpson avatar mrsimpson commented on June 6, 2024

@auchenberg weโ€™re using Meteor 1.6.0.1 at this vier moment and node 8.9.4.
i know the short guide (thanks a ton) and also tried those very intuitive launch configurable (which made me think that you somehow had to do a lot specificall for Meteor).
I also successfully debugged the sample app.
I really think it has to do something with the colons. Iโ€™ll try just renaming the folder on the disk and revert to you afterwards, this will verify/falsify my hypothesis

from vscode-node-debug.

mrsimpson avatar mrsimpson commented on June 6, 2024

yup - verified ๐ŸŽ‰

I renamed the package in the package-definition to that it matches the path on disk to assistify-ai.
Now, a breakpoint in a server-side-file of this packages turned red and the debugger stops as expected.

One could argue this not being an issue of the debugger but more a systematic issue of the environment. And I couldn't disagree much. However, this problem is widespread due to historic reasons which are still a recommendation:

But wait, what's up with the colon convention in the demo?
Prior to Meteor v1.1.0, Meteor used to create packages using the colon syntax to match how it references packages on the package server. As v1.1.0 introduced Windows support, they had to drop the colon syntax when creating folders as Windows machines don't support it. Bonk. Keep in mind: you still add packages using the colon syntax in your terminal like meteor add author:package.

So a bit of heuristic on finding the proper file (once the one guessed is not found in _findGeneratedToSourceMapping). It's really about the colon. Assuming the map states package:name, the target file usually resides in a folder called either package-name or simply name. Do you think this is manageable?

Renaming the folders is not an option since this was very disruptive to the code base :(

from vscode-node-debug.

roblourens avatar roblourens commented on June 6, 2024

Glad that worked, yeah regex replace would help in this situation, but that level of control isn't often needed.

from vscode-node-debug.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.