kondratyev-nv / vscode-python-test-adapter

Python Test Adapter for the VS Code Test Explorer
https://marketplace.visualstudio.com/items?itemName=LittleFoxTeam.vscode-python-test-adapter
MIT License
117 stars 27 forks source link

launch.json reports that '"request": "test",' is invalid, wants "attach" instead. #280

Closed MarximusMaximus closed 2 years ago

MarximusMaximus commented 2 years ago

When adding

        {
            "name": "Python: Debug Test (PythonTestExplorer)",
            "type": "python",
            "request": "test",
            "justMyCode": false,
        }

to launch.json, VSCode complains that "test" is an invalid valid for "request". It wants to use "attach" instead. Please support checking for either string, so as to be backwards compatible (test) but also to stop VSCode from complaining (attach).

Screen Shot 2022-04-07 at 15 36 30

Thank you.

kondratyev-nv commented 2 years ago

@MarximusMaximus I've added support for "purpose": ["debug-test"] and any "request" to detect a valid debug configuration. Please, update to version 0.7.1 and let me know if this works for you.

MarximusMaximus commented 2 years ago

Seems to work. Thank you!