Calling .Net code from Python Lambda - Is it possible

0

Hello,

I am desperately looking for help on this. Using PythonNet package I am trying to call .Net code from a Python Lambda function. But while trying to deploy that to .Net Lambda I get the following error saying that it is unable to load the runtime.

Response { "errorMessage": "Failed to create a .NET runtime (coreclr) using the\n parameters {}.", "errorType": "RuntimeError", "requestId": "", "stackTrace": [ " File "/var/lang/lib/python3.9/importlib/init.py", line 127, in import_module\n return _bootstrap._gcd_import(name[level:], package, level)\n", " File "<frozen importlib._bootstrap>", line 1030, in _gcd_import\n", " File "<frozen importlib._bootstrap>", line 1007, in _find_and_load\n", " File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked\n", " File "<frozen importlib._bootstrap>", line 680, in _load_unlocked\n", " File "<frozen importlib._bootstrap_external>", line 850, in exec_module\n", " File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed\n",

Thanks, Haripriya

질문됨 일 년 전667회 조회
2개 답변
0

Hello,

In short, yes you can run .NET code in lambda. It looks like you are trying to use the .NET core runtime which makes sense. What version of .NET are you using? Have you looked at the doc below yet as well? https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html

Cloud_G
답변함 일 년 전
0

Thank you Cloud_G for the prompt reply. I am using .Net core 3.1 [assembly: TargetFramework(".NETCoreApp,Version=v3.1", FrameworkDisplayName = ".NET Core 3.1")] Could you please help me with a sample Lambda that calls .Net code in Python or containerizing to include both run times and successfully executing the lambda?

Thanks, Haripriya

답변함 일 년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠