Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unable to debug in vscode #24

Open
cs-a50494 opened this issue Nov 14, 2017 · 5 comments
Open

unable to debug in vscode #24

cs-a50494 opened this issue Nov 14, 2017 · 5 comments

Comments

@cs-a50494
Copy link

It would be nice to have a setup for debugging in vscode.

@yxd-hde
Copy link
Contributor

yxd-hde commented Dec 14, 2017

PR is welcomed.

@mark-bixler
Copy link

Did anyone ever get this figured out? I had it on Mac, but can't get debugging working on Windows :(

@maxmonterumisi
Copy link

Can someone help me configure python-lambda-local under VSC (Windows 10) please ?

@emepetres
Copy link

By using pytest, I'm able to debug it out of the box, without any specific configuration. Just set a break point, and execute the test within vscode.

Probably with unittests or nosetests will work as well: https://code.visualstudio.com/docs/python/unit-testing#_enable-a-test-framework

@ggaller
Copy link

ggaller commented May 15, 2023

This is working VS Code debug configuration for launch.json:

{
    "name": "Lambda: My Lambda",
    "type": "python",
    "request": "launch",
    "module": "lambda_local",
    "args": [
              "-l", "${workspaceFolder}/.venv/lib",
              "-f", "lambda_handler",
              "-t", "180",
              "-e", "${workspaceFolder}/env.json",
              "${workspaceFolder}/lambda_function.py",
              "${workspaceFolder}/events/event.json"
    ],
    "console": "internalConsole",
    "internalConsoleOptions": "openOnSessionStart",
    "env": {
        "AWS_PROFILE": "some-profile",
        "AWS_DEFAULT_REGION": "eu-central-1"
    }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants