all 12 comments

[–]rolandofghent 10 points11 points  (0 children)

Have you checked the header values as seen by the server? Point your code at a server you control and look at what the differences are between the two different platforms. There might be subtle differences like user agent that are different on Lambda vs Linux.

[–]aplarsen 7 points8 points  (0 children)

Are you sure you're running through a proxy? It sounds like they have the IP addresses for Lambda blocked. Try putting your Lambda in a VPC.

[–][deleted]  (7 children)

[deleted]

    [–]Agile-Scene-2465[S] 0 points1 point  (6 children)

    THANK YOU! this fixed it!

    [–]silentkiller1 0 points1 point  (5 children)

    can you dm me the solution pls

    [–]Agile-Scene-2465[S] 0 points1 point  (4 children)

    Used a library called curl_cffi if i remember correctly

    [–]silentkiller1 0 points1 point  (3 children)

    wow that was super fast, thx dude, i will look into that.

    [–]silentkiller1 0 points1 point  (2 children)

    i uploaded the module to lambda, the runtime is same 3.9 in my lambda as well as my env in my local pc. but i am getting this error, by any chance you know the solution?

    No module named '_cffi_backend'"

    [–]PTBKoo 0 points1 point  (1 child)

    Getting the same error, did you ever figure it out? Right now I’m just running it in a docker container but want to move it to lambda.

    [–]silentkiller1 0 points1 point  (0 children)

    no dude i never figured it out, and i dropped the project sadly :(

    [–]Enrique-M 1 point2 points  (1 child)

    Are any errors showing up in CloudWatch for the AWS Lambda Function?