Я разрабатываю лямбда-проект, используя Python версии 3.12 в качестве языка программирования. Я разработал простой API, и когда я запускаю проект локально, он показывает следующую ошибку:
START RequestId: f4eac928-9658-44f0-9193-46bb4162f297 Version: $LATEST
LAMBDA_WARNING: Unhandled exception. The most likely cause is an issue in the function code. However, in rare cases, a Lambda runtime update can cause unexpected function behavior. For functions using managed runtimes, runtime updates can be triggered by a function change, or can be applied automatically. To determine if the runtime has been updated, check the runtime version in the INIT_START log entry. If this error correlates with a change in the runtime version, you may be able to mitigate this error by temporarily rolling back to the previous runtime version. For more information, see https://docs.aws.amazon.com/lambda/latest/dg/runtimes-update.html
[ERROR] Runtime.ImportModuleError: Unable to import module 'main': No module named 'botocore.vendored.six.moves'
Traceback (most recent call last):
END RequestId: 064be081-c61f-4494-ab47-ee1382c83196
REPORT RequestId: 064be081-c61f-4494-ab47-ee1382c83196 Init Duration: 0.09 ms Duration: 370.09 ms Billed Duration: 371 ms Memory Size: 128 MB Max Memory Used: 128 MB
{"errorMessage": "Unable to import module 'main': No module named 'botocore.vendored.six.moves'", "errorType": "Runtime.ImportModuleError", "requestId": "064be081-c61f-4494-ab47-ee1382c83196", "stackTrace": []}
Я обновил boto3, botocore и awscli:
pip install --upgrade boto3
pip install --upgrade botocore
pip install --upgrade awscli
Но он по-прежнему показывает ту же ошибку, упомянутую выше.
Кто-нибудь может мне помочь?
Извините за мой английский, я использовал Google Translate






Ресурс Amazon (ARN) имел версию 3.8. Я обновил ARN до версии 3.12.