-
Notifications
You must be signed in to change notification settings - Fork 320
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
[BUG] Python 3.11 > aws-psycopg2 >> "Unable to import module 'lambda_function': No module named 'psycopg2._psycopg'" #392
Comments
Can you share your full code? Is there a lambda_function.lambda_handler method somewhere here? |
Sorry to hear that, will look into this later this week. |
Hi there! Just ran into the same issue - anything I can do to help debug? |
I also run into the same issue. Will return error: |
Getting the same issue with 3.12 |
HI Folks, can you try the latest layer. It 'hopefully' resolves the issue. arn:aws:lambda:us-east-2:770693421928:layer:Klayers-p311-psycopg:10 Replace the region with the one you're using. |
Can confirm that I was able to get this to work on |
Yay! Thanks @austinulfers The fix was to pip install Thankfully this fixes it -- but I'll need to figure out how to incorporate this build with the optional dependencies. |
Closing. Please re-open if this doesn't work. |
Describe the bug
I import the module as "import psycopg2" and then I tried to use it as "psycopg2.connect(conn_string)" with no success
Screenshots
Layer Version ARN:
arn:aws:lambda:eu-central-1:770693421928:layer:Klayers-p311-aws-psycopg2:1
Framework:
Console
Additional context
The text was updated successfully, but these errors were encountered: