Skip to content

.vscode/launch.json doesn't attach breakpoints when code's cwd is the monorepo #195

Closed
@JoshuaKGoldberg

Description

@JoshuaKGoldberg

Repro

  1. Launch code . from the monorepo's root
  2. Navigate to a rule's source file under eslint-plugin, such as packages/eslint-plugin/tests/lib/rules/ban-types.js
  3. Put a breakpoint within the rule's logic
  4. Launch "Jest Test Current eslint-plugin Rule"

Breakpoints won't attach. This is the terminal output instead:

Microsoft Windows [Version 10.0.17134.523]
(c) 2018 Microsoft Corporation. All rights reserved.

C:\Code\typescript-eslint>cd C:\Code\typescript-eslint/packages/eslint-plugin/ && "C:\Program Files\nodejs\node.exe" --inspect-brk=7813 ..\..\node_modules\jest\bin\jest.js --colors packages/eslint-plugin/tests/lib/rules/launch.json
Debugger listening on ws://127.0.0.1:7813/417c19e4-b31f-4d42-be99-7efac7120d30
For help see https://nodejs.org/en/docs/inspector
Debugger attached.
No tests found
In C:\Code\typescript-eslint\packages\eslint-plugin
  94 files checked.
  testMatch:  - 94 matches
  testPathIgnorePatterns: \\node_modules\\ - 94 matches
  testRegex: .\\tests\\lib\\.+\.js$ - 48 matches
Pattern: packages\\eslint-plugin\\tests\\lib\\rules\\launch.json - 0 matches
Waiting for the debugger to disconnect...

C:\Code\typescript-eslint\packages\eslint-plugin>

I'm on Windows 10 with Cmder, if that helps.

Metadata

Metadata

Assignees

No one assigned

    Labels

    package: eslint-pluginIssues related to @typescript-eslint/eslint-plugintriageWaiting for team members to take a look

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions