Open josh-burton opened 2 months ago
Hello @josh-burton. Please provide a minimal reproduction using a GitHub repository or StackBlitz (you can also use examples). Issues marked with needs reproduction
will be closed if they have no activity within 3 days.
I'm unsure how to create a reproducible sample using stackblitz as I would need to publish another package to demonstrate that debugging does not work.
Is there a way to replicate publishing a package without actually publishing a package to npm?
You can also create
a minimal reproduction using a GitHub repository
and there have manually created node_modules
which contains the package that demonstrates the issue. It doesn't have to be published package, just create it under node_modules
and commit the changes to git remote.
You can also create
a minimal reproduction using a GitHub repository
and there have manually created
node_modules
which contains the package that demonstrates the issue. It doesn't have to be published package, just create it undernode_modules
and commit the changes to git remote.
ok thanks :) I'll do that.
@AriPerkkio I've created a reproducible sample here: https://github.com/josh-burton/vitest-debugging-bug
Are you able to reopen the issue?
The sample project has:
my_dependency
inside of node_modulesindex.test.ts
If a breakpoint is set inside index.test.ts
, it is hit when debugging:
If a breakpoint is set inside of node_modules/my_dependency/src/repository/my_repository
, it is never hit when debugging:
Some notes:
npx link
with the dependency (which symlinks the dependency into node_modules), I'm able to debug fine.I've also filed a Youtrack issue for IntelliJ: https://youtrack.jetbrains.com/issue/IDEA-357178/vitest-unable-to-hit-debug-breakpoint-inside-a-nodemodules-dependency
Describe the bug
I have a few internal dependencies that only contain typescript source files - no compiled javascript.
Until this point I've been using jest, and compilation and debugging these files has worked fine.
When migrating to vitest, compilation works, but I'm unable to set break points within these files.
Is there any config required to allow debugging the typescript source?
Reproduction
A nodejs typescript project compiling a published typescript package, built with
tsc --noEmit
.A debug breakpoint set within the published typescript package is not hit.
System Info
Used Package Manager
npm
Validations