question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

vscode-jest activates for all folders in a multi-root workspace if any folder contains jest-related files

See original GitHub issue

vscode-jest activates for all roots in a multi-root workspace if any folder contains jest-related files. When it activates on folders that don’t have jest files, it spams a bunch of error messages.

Expected Behavior

Don’t show errors on roots where there are no jest files.

Actual Behavior

Shows errors on roots that don’t use jest.

Screen Shot 2020-05-05 at 1 19 15 PM (1)

Workaround

It seems like only way to reduce scope would be to exhaustively list all folders where Jest should be disabled with jest.disabledWorkspaceFolders - there’s no way to specify a whitelist of folders where Jest should run (which would be better).

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:10
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

8reactions
connectdotzcommented, May 8, 2020

While this feature is definitely nice to have, it is the expected behavior for the current implementation: instead of doing a deep search for jest files on each folder, it took a simpler approach by providing a customize-option… As the error panel indicated above, you can skip these folders by adding "jest.disabledWorkspaceFolders": ['interviews', 'deploy-sourcegraph'] to .vscode/settings.json or the equivalent.

PR is welcome.

1reaction
jonnytest1commented, Aug 18, 2022
Read more comments on GitHub >

github_iconTop Results From Across the Web

Multi-root Workspaces in Visual Studio Code
You can open and work on multiple project folders in Visual Studio Code with ... The File > Add Folder to Workspace command...
Read more >
vscode-jest does not start when the workspace folder name ...
the main folder for the multi-root workspace had blanks in its ... Failure to start jest if the project root folder contains space,...
Read more >
Jest - Open VSX Registry
Test menu is now accessible for all tests, regardless of run mode. ... project as a multi-root workspaces in vscode, which each sub...
Read more >
How to exclude all files in one of the multi-root workspace ...
I have a multi-root workspace set up, in which two out of the four folders are external thus I can't add specific settings...
Read more >
vscode open file as root - Industry Today
With multi-root workspaces, there is a SOURCE CONTROL PROVIDERS section that gives you an overview when you have multiple active repositories. Find centralized, ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found