azure-functions-durable-python v1.6.0: No. A Python Durable Entity cannot signal itself—or any entity—from entity code, immediately or on a schedule.
microsoft/durabletask-python: Yes, in durabletask>=1.7.0. The current v1.7.2 release supports exactly this pattern.
| Capability | Azure Functions Python v1.6.0 | durabletask v1.7.2 |
|---|---|---|
| Entity → immediate self-signal | No | Yes |
| Entity → scheduled self-signal | No | Yes |
| Orchestrator → scheduled entity signal | No public API | Yes |
| Client → scheduled entity signal | No | Yes |
DurableEntityContext exposes only state, input, result, and deletion operations. It has no outbound messaging API.
The other available surfaces are immediate-only:
DurableOrchestrationContext.signal_entityhas no scheduled-time argument.DurableOrchestrationClient.signal_entityis also immediate-only.SignalEntityActionserializes no delivery time.
The official documentation explicitly confirms: “Python doesn't support entity-to-entity signals. Use an orchestrator to signal entities instead.”
The Azure Functions extension supports scheduled entity signals for in-process .NET using RequestMessage.ScheduledTime ("due"). However, its out-of-process entity response protocol only accepts:
signals[{ target, name, input }]
There is no scheduled-time field, and the host never copies one into RequestMessage.ScheduledTime. This is tracked by the still-open extension issue #1554: Support Entity-to-Entity Scheduled SignalEntities for OutOfProc PLs.
Therefore, implementing the exact feature in this repository requires coordinated work:
- Durable Functions extension: add scheduled time to
TaskEntityShim.OutOfProcResult.Signaland propagate it intoRequestMessage.ScheduledTime. - Python SDK: add
DurableEntityContext.signal_entity, collect outgoing signals, expose self identity, and serialize the scheduled time. - Compatibility protection: older hosts would ignore the new field and deliver the message immediately, so a minimum extension version or capability negotiation is essential.
Adjacent findings:
- Immediate entity-to-self/entity-to-entity signaling could be added package-only because the existing
signals[]protocol already supports it. - Scheduled signaling from an orchestrator is already implemented by the host as action type
10, but Python does not expose it. - Scheduled signaling through
DurableOrchestrationClientwould require a small host HTTP endpoint change.
The currently available workaround is an orchestrator:
yield context.create_timer(deadline)
context.signal_entity(entity_id, "wake_up", payload)That is durable but requires a separate orchestration and cannot be initiated directly by the entity.
Support was added in PR #160, shipped in v1.7.0, and remains in the current v1.7.2.
The API is:
ctx.signal_entity(
ctx.entity_id,
"wake_up",
input=payload,
signal_time=wake_at_utc,
)EntityContext.signal_entity explicitly documents signal_time as useful “to have an entity wake itself up at a later time.” It serializes to the protobuf SendSignalAction.scheduledTime field.
This is not just an exposed but unused API:
- The shipped
durabletask.scheduledSchedule entity re-arms itself with a futuresignal_time. - Unit tests verify that the self-signal contains
scheduledTime. - End-to-end tests exercise recurring self-scheduling against both the in-memory backend and the Durable Task Scheduler emulator.
- It is a one-way, fire-and-forget signal; results and handler errors are not returned.
- The scheduled time is a not-before deadline, not an exact execution time.
- Entity operations remain serialized; self-signaling does not invoke the entity reentrantly.
- There is no cancellation handle. The shipped scheduler uses an execution token so obsolete scheduled signals become no-ops.
- Deleting state does not reliably cancel an already queued signal; handlers should tolerate stale delivery.
- Use timezone-aware UTC
datetimevalues. - No service-specific maximum delay or minimum DTS version is currently documented.
- The repository has live DTS coverage, but only against the unpinned
dts-emulator:latest.
Most importantly, durabletask-python is explicitly not compatible with Azure Durable Functions. It targets Azure Durable Task Scheduler, so it cannot simply be imported into an existing Functions application.
Recommendation: for Azure Functions, treat this as a coordinated extension + Python SDK feature based on issue #1554. For Durable Task Scheduler workloads, the feature is already available and production-shaped in durabletask>=1.7.0.