Skip to content

Pytest debug doesn't work with Multi-root Workspace #2330

@xahgmah

Description

@xahgmah

Environment data

  • VS Code version: 1.25.1
  • Extension version: 2018.7.1
  • OS and version: macOS High Sierra 10.13.5
  • Python version: 2.7.15
  • Type of virtual environment used: virtualenv

Actual behavior

Can't run "Debug All Unit Tests". Receive debug error immediately.
screen shot 2018-08-03 at 18 47 45

Doesn't matter which project I am trying to run.

If I open one of folders separately it works fine.

Expected behavior

Debug functionality works for Multi-root Workspace.

Steps to reproduce:

  1. Create new workspace
  2. Add several projects by clicking "Add Folder to Workspace"
  3. Setup environment
  4. Cmd+P -> "Python: Debug All Unit Tests"

Logs

Workspace settings are default
Folder settings

{
    "python.linting.pylintArgs": [
        "--load-plugins",
        "pylint_django"
    ],
    "python.pythonPath": "${workspaceFolder}/venv/bin/python",
    "python.unitTest.unittestEnabled": false,
    "python.unitTest.nosetestsEnabled": false,
    "python.unitTest.pyTestEnabled": true,
    "python.unitTest.pyTestArgs": [
        "src/tests",
    ]
}

Output is empty

Debug console:
IndexError, list index out of range

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-debuggingbugIssue identified by VS Code Team member as probable buginfo-neededIssue requires more information from poster

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions