Skip to content

visualstudio_py_testlauncher.py - format_exception() missing 3 required positional arguments: 'etype', 'value', and 'tb' #3305

@Ark-kun

Description

@Ark-kun

I got an exception while trying to debug a unittest. The exception was from a bug in VSCode Python extension itself:

Exception has occurred: TypeError
format_exception() missing 3 required positional arguments: 'etype', 'value', and 'tb'
  File "C:\Users\Ark\.vscode\extensions\ms-python.python-2018.9.2\pythonFiles\PythonTools\visualstudio_py_testlauncher.py", line 344, in main
    pass
  File "C:\Users\Ark\.vscode\extensions\ms-python.python-2018.9.2\pythonFiles\PythonTools\visualstudio_py_testlauncher.py", line 347, in <module>
    main()

I looked at the extension's code and the error is correct. See DonJayamanne@3e50a68#r31258938

Environment data

  • VS Code version: 1.28.2
  • Extension version: 2018-10-01
  • OS and version: Windows 10
  • Python version: 3.7.0 x64
  • Type of virtual environment used: N/A

Actual behavior

Exception has occurred: TypeError
format_exception() missing 3 required positional arguments: 'etype', 'value', and 'tb'
  File "C:\Users\Ark\.vscode\extensions\ms-python.python-2018.9.2\pythonFiles\PythonTools\visualstudio_py_testlauncher.py", line 344, in main
    pass
  File "C:\Users\Ark\.vscode\extensions\ms-python.python-2018.9.2\pythonFiles\PythonTools\visualstudio_py_testlauncher.py", line 347, in <module>
    main()

Expected behavior

No exception

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-testingbugIssue identified by VS Code Team member as probable bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions