Worker failed to load Durable Entity function when binding a Storage Queue
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 48/100
Hướng nghiên cứu
Bắt đầu với init.py và function.json của sample Counter đã tái hiện, sau đó theo dõi cách entry point entity_function được tải và cách binding outputQueueItem của nó được xác thực. Chạy reproducer cục bộ và so sánh việc tải function khi binding queue hiện diện; hoàn thành khi function Counter tải thành công với output Storage Queue được khai báo.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
🐛 Describe the bug
I'm learning about Durable Entities , not sure if this is supported or not. I'm using counter sample provided here and trying to bind a Storage Queue . However worker complains about not finding the corresponding parameter:
[2022-07-22T15:02:30.124Z] Worker failed to load function: 'Counter' with function id: 'a80f6d9c-8814-4549-bc62-155546eaf880'.
[2022-07-22T15:02:30.125Z] Result: Failure
Exception: FunctionLoadError: cannot load the Counter function: the following parameters are declared in function.json but not in Python: {'outputQueueItem'}
🤔 Expected behavior
What should have happened?
Worker is able to load Function
☕ Steps to reproduce
What Durable Functions patterns are you using, if any?
HTTPTrigger > Orchestration > Entity
Any minimal reproducer we can use?
https://github.com/enriqueayala/azure-function-counter.git
_ init.py _
import logging
import json
import azure.functions as func
import azure.durable_functions as df
def entity_function(context: df.DurableEntityContext, outputQueueItem: func.Out[str]):
"""A Counter Durable Entity.
A simple example of a Durable Entity that implements
a simple counter.
Parameters
----------
context (df.DurableEntityContext):
The Durable Entity context, which exports an API
for implementing durable entities.
"""
current_value = context.get_state(lambda: 0)
operation = context.operation_name
if operation == "add":
amount = context.get_input()
current_value += amount
elif operation == "reset":
current_value = 0
elif operation == "get":
pass
context.set_state(current_value)
context.set_result(current_value)
outputQueueItem.set(current_value)
main = df.Entity.create(entity_function)
function.json
{
"scriptFile": "__init__.py",
"bindings": [
{
"name": "context",
"type": "entityTrigger",
"direction": "in"
},
{
"type": "queue",
"direction": "out",
"name": "outputQueueItem",
"queueName": "outqueue",
"connection": "AzureWebJobsStorage"
}
]
}
Are you running this locally or on Azure?
Locally
- Ngôn ngữ chính
- Python
- Star
- 157
- Fork
- 70
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của Azure/azure-functions-durable-python
-
Enhancement fixed-in-v2 P3
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Azure/azure-functions-durable-python#617 · 1 bình luận ·
-
bug Debuggability fixed-in-v2 P2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Azure/azure-functions-durable-python#587 · 2 bình luận · 1 reaction ·
-
Custom object serialization broken for orchestrator return valuesCó thể đã có người làm @andystaples đã nhận 68 ngày trước. Đang mởbug fixed-in-v2 P2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
Azure/azure-functions-durable-python#568 · 1 bình luận ·
-
bug fixed-in-v2 P3
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Azure/azure-functions-durable-python#475 · 1 bình luận ·
-
Enhancement fixed-in-v2 P3
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 62/100
Azure/azure-functions-durable-python#618 · 1 bình luận ·
Tất cả issue của Azure/azure-functions-durable-python
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
RedHatQE/mtv-api-tests#721 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 85/100
pytest-dev/pluggy#757 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 85/100
NousResearch/hermes-agent#134960 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
HTML backend: `<br>` leaks the internal sentinel U+E000 into list items, headings and captionsCó thể đã có người làm @morten-lagabote đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 67/100
docling-project/docling#4671 ·
Maintainer thường phản hồi trong vòng 1 ngày