AWS lambda Python functions gives error to install the "google-cloud-firestore" module, but is already installed
還沒有人認領這個 Issue。
評估
- 難度
- 3/5
- 預估耗時
- 1-2 天
- 新手友好度
- 35/100
研究方向
從 lambda_function 和透過 pip install --target . firebase-admin==5.2.0 以及 pip install --target . grpcio 產生的已上傳套件開始。重現 AWS Lambda 匯入失敗,並檢查套件內容和執行階段錯誤。當部署的 Python 3.9 函式能夠匯入並使用 Cloud Firestore,且不再出現缺少模組的錯誤時,即表示完成。
由索引模型根據 Issue 內容生成。
描述
Operating System version: AWS Python lambda
Firebase SDK version: firebase-admin 5.2.0
Firebase Product: google cloud firestore
Python version: 3.9
Hi I have an AWS Lambda in Python 3.9 (now regenerated in AWS functions console),I have installed in my local aws folder firebase-admin & dependencies:
pip install --target . firebase-admin==5.2.0
This installation gives me this error:

And finally I have implemented my Python AWS lambda, and upload to AWS lambda as ZIP file a package to the AWS code function console. When I tried to execute my testing in the Python Lambda, this gives me this error:
{
"errorMessage": "Unable to import module 'lambda_function': Failed to import the Cloud Firestore library for Python. Make sure to install the \"google-cloud-firestore\" module.",
"errorType": "Runtime.ImportModuleError",
"stackTrace": []
}
I also installed in my local directory the grpcio module, before to upload ZIP file in AWS function console, with this command:
pip install --target . grpcio
And finally upload all my directory in a package to the AWS function console.
But the same error is displayed when I execute a test in AWS cloud function.
{
"errorMessage": "Unable to import module 'lambda_function': Failed to import the Cloud Firestore library for Python. Make sure to install the \"google-cloud-firestore\" module.", ....
}
This is my full directory:

What can I do to solve this error? & made available google-cloud-firestore works fine in my AWS Lambda Python?
Thanks!
- 主要語言
- Python
- 星號
- 1.2k
- 分支
- 359
- 平均合併
- 3 天 9 小時
- 30 天內合併 PR
- 3
貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
firebase/firebase-admin-python 的其他 Issue
-
api: remoteconfig
難度 2/5 1-3 小時 新手友好度 75/100
firebase/firebase-admin-python#957 · 1 則留言 ·
-
api: database type: feature request
難度 2/5 1-3 小時 新手友好度 62/100
-
難度 4/5 3-5 天 新手友好度 45/100
firebase/firebase-admin-python#978 · 1 則留言 ·
-
[FR] Support VERIFY_AND_CHANGE_EMAIL in generate_email_action_link (parity with firebase-admin-node) 未關閉api: auth
firebase/firebase-admin-python#949 · 2 則留言 · 1 個 reaction · 已指派 1 人 ·
-
難度 4/5 3-5 天 新手友好度 43/100
firebase/firebase-admin-python#945 · 1 則留言 · 1 個 reaction ·
查看 firebase/firebase-admin-python 的全部 Issue
相似的 Issue
-
bug confirmed issue
難度 2/5 1-3 小時 新手友好度 75/100
open-webui/open-webui#30750 · 1 則留言 ·
-
難度 2/5 1-3 小時 新手友好度 75/100
-
enhancement
難度 2/5 1-3 小時 新手友好度 75/100
OpenwaterHealth/openmotion-bloodflow-app#604 · 1 則留言 ·
-
難度 2/5 1-3 小時 新手友好度 70/100
-
good first issue
難度 1/5 1 小時以內 新手友好度 90/100