Comments (3)
Update:
I've noticed the following:
- Breakpoints in the log file being executed are bound properly and immediately.
- Breakpoints in the API packages are eventually bound, when the debugger is fully started
- Breakpoints in the common package are never bound, and even after the debugger is fully started, it's impossible to set any in the common package
- Stepping into code from the common package shows incorrect lines/files
Sent another log file when going through the steps that lead to the above conclusions.
from vscode-js-debug.
This is a common issue in monorepos, you're building your "common" code, but then your tooling is not "following" the sourcemaps in the compiled code. When it's bundling the code, it's creating sourcemaps that reference the already compiled bundle rather than your actual source code, e.g.
{
"version": 3,
"sources": [
"chunk-ZZYPPKAZ.js" // <- should be your actual sources, not just the chunk
],
I think that you might not be building with sourcemaps in your common code, as both vitest/esbuild and js-debug have logic that may handle this case if that were so.
from vscode-js-debug.
@connor4312 Thanks for the reply.
Actually, we do generate source maps for our common package. In fact, everything was working fine not too long ago. I tried going as far as 3 months back into our commit history, but still have the same issues with the debugger, which leads me to believe that we're either doing something wrong with our launch configs, or something changed with the debugger.
Based on your comment, I tried disabling code splitting in our bundler. This eliminates all the chunk files. Still getting the exact same issue though. Sent another log file to your email with that.
Here's another look into my issues:
This is the result after clicking twice on line 308 in calculateUtilities.ts
. As you can see, the breakpoints make no sense.
from vscode-js-debug.
Related Issues (20)
- The debugger does not work in a monorepo when bundle size and sourcemaps go over a certain size HOT 12
- Proxy support for npx gulp vsDebugServer HOT 3
- Chrome DevTools window is always auto-opened for extension popup HOT 5
- How does auto attach knows where to look for the sourcemap files? HOT 7
- Breakpoints unbound, VSCode cannot find source maps HOT 15
- Failed to start inspector port on WSL 2 mirrored network HOT 3
- Fix preview rendering of number '0' when 'description' is not set. HOT 2
- When `NODE_OPTIONS` is configured for a dev container, js-debug interferes with it
- debugger not working
- Easier way to jump to function definitions in debug log.
- VS Code built-in extension breakpoints could not be set. HOT 3
- When the Debug for Chrome plugin is running, the browser plugin is gone HOT 7
- Resolve executables in node_modules/.bin directly HOT 1
- Electron render Typescript debugging breakpoints work in vscode natively, but not inside a dev container HOT 4
- Error on vscode js debug terminal HOT 1
- Support external terminal option HOT 2
- Some of your breakpoints could not be set (greyed out) HOT 5
- added "sourceMap": true, to tsconfig still get issue HOT 1
- Unbound breakpoint HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vscode-js-debug.