Skip to content

Ignore: draft PR to run CI only #822

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 3 additions & 6 deletions temporalio/worker/_workflow_instance.py
Original file line number Diff line number Diff line change
Expand Up @@ -1594,6 +1594,7 @@ def apply_child_cancel_error() -> None:
# If the cancel command is for external workflow, we
# have to add a seq and mark it pending
if cancel_command.HasField("request_cancel_external_workflow_execution"):
assert False, "request_cancel_external_workflow_execution"
cancel_seq = self._next_seq("external_cancel")
cancel_command.request_cancel_external_workflow_execution.seq = (
cancel_seq
Expand All @@ -1609,9 +1610,7 @@ async def run_child() -> Any:
while True:
assert handle
try:
# We have to shield because we don't want the future itself
# to be cancelled
return await asyncio.shield(handle._result_fut)
return await handle._result_fut
except asyncio.CancelledError:
apply_child_cancel_error()

Expand All @@ -1625,9 +1624,7 @@ async def run_child() -> Any:
# Wait on start before returning
while True:
try:
# We have to shield because we don't want the future itself
# to be cancelled
await asyncio.shield(handle._start_fut)
await handle._start_fut
return handle
except asyncio.CancelledError:
apply_child_cancel_error()
Expand Down
Loading