VSCode

Page content

settings.json

Useful Settings for VSCode … settings.json

{
    "python.linting.enabled": true,
    "python.linting.pylintEnabled": true,
    "python.formatting.provider": "black",
    "python.formatting.blackArgs": [
        "--line-length=100"
    ],
    "python.sortImports.args": [
        "--profile", "black"
    ],
    "editor.formatOnSave": false,
    "[python]": {
        "editor.formatOnSave": true,
        "editor.codeActionsOnSave": {
            "source.organizeImports": true
        },
    },
}

launch.json

launch.json

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Python: Test001",
            "type": "python",
            "request": "launch",
            // adapt this path below if needed, it assumes automation_cli is open as
            // root folder in your vscode workspace.
            "program": "${workspaceFolder}/project/code.py",
            "args": ["arg1", "arg2", "arg3"],
            "console": "integratedTerminal"
        },
        // default config to debug your current active file with python
        {
            "name": "Python: Current File",
            "type": "python",
            "request": "launch",
            "program": "${file}",
            "console": "integratedTerminal"
        }
    ]
}

sha256: 3cf38a94519408317e8dcbb88a6a636b9070238d2111df10c04f7c181b02bc43