首页 > 解决方案 > Firebase Python admin sdk - 交易未进行,无法在 API 请求中使用

问题描述

我正面临上述错误。仅当我的代码部署为云功能时才会出现此错误。我没有使用事务装饰器

我的场景是 Function1()---transaction=db.transaction --->Function2(transaction)--does some things----function3(transaction)

然后 Function1 提交事务。它曾经工作,但突然它不工作。有人可以指导我,我如何使用python实现这个。

我找不到任何示例 - 它显示了 transaction._begin 和 transaction.commit 的示例

标签: pythongoogle-cloud-firestore

解决方案


推荐阅读