python - Azure 函数 Python - 错误“未注册绑定类型‘blobTrigger’”
问题描述
我试图在我的 Mac 上本地运行 Azure 函数并收到以下错误:The binding type(s) 'blobTrigger' are not registered. Please ensure the type is correct and the binding extension is installed.
我正在使用 homebrew ( )Python 3.6.8
进行安装。azure-functions-core-tools
brew tap azure/functions; brew install azure-functions-core-tools
使用预期的配置设置我的local.settings.json
文件,因此函数应该侦听托管在 azure 中的正确存储容器。
我确定自从上周工作以来我没有更改任何代码或配置文件。
host.json 文件包含:
{
"version": "2.0",
"extensionBundle": {
"id": "Microsoft.Azure.Functions.ExtensionBundle",
"version": "[1.*, 2.0.0)"
}
}
function.json 文件包含:
{
"scriptFile": "__init__.py",
"bindings": [
{
"name": "xmlblob",
"type": "blobTrigger",
"direction": "in",
"path": "<directory>/{name}",
"connection": "AzureStorageAccountConnectionString"
}
]
}
requirements.txt 文件包含:
azure-cosmos==3.1.0
azure-functions-worker==1.0.0b6
azure-storage==0.36.0
azure-storage-blob==2.0.1
xmljson==0.2.0
xmlschema==1.0.11
然后我在终端中运行以下命令:
1) pip install -r requirements.txt
2) source .env/bin/activate
3) func host start
然后我收到以下错误:
<Application name>: The binding type(s) 'blobTrigger' are not registered. Please ensure the type is correct and the binding extension is installed.
解决方案
推荐阅读
- c++11 - 有没有办法从外部控制 C++ 代码流?
- css - 忽略 vscode live sass 编译器中的一些 .scss 文件
- linux - 如何创建自己的 linux 显示驱动程序
- hash - 如何仅从命令行获取哈希?
- windows - 有人可以告诉我这个 FOR 循环有什么问题吗?
- java - 如何将点击事件添加到 Java 中的二维瓷砖对象数组
- openlayers - 将文本放在绘制区域的中间打开图层
- windows - 我们不能将 abc.c 和 ABC.c 放在同一个文件夹中吗?有人可以解释一下原因吗
- sql - 查找表 Y 中与表 X 中的时间最接近的时间
- php - Wordpress 置顶帖复选框未保存