[Bug] Python: replayed Local Activity timeout causes NDE (TimeoutError not wrapped in ActivityError)

未關閉
#2,183 0 則留言 0 個 reaction 已指派 1 人 在 GitHub 檢視

維護者通常 1 天內回覆

@mjameswh 已經在處理了。

開始於 2026年12月2日。

評估

這個 Issue 還沒有評估資料。

描述

bug sdk-python

Description:

The workflow runs a Local Activity that times out (start_to_close_timeout, retries exhausted), catches ActivityError, and calls workflow.sleep() in the except.

 try:
            # Attempt 1 times out; its 10s backoff is over the 5s threshold, so the worker records a
            # failure marker and a backoff timer. Attempt 2 times out and the error reaches this code.
            await workflow.execute_local_activity(
                slow_check,
                start_to_close_timeout=timedelta(seconds=5),
                retry_policy=RetryPolicy(initial_interval=timedelta(seconds=10), maximum_attempts=2),
                local_retry_threshold=timedelta(seconds=5),
            )
        except ActivityError:
            await workflow.sleep(timedelta(seconds=1), summary="sleep in except ActivityError")
        # Fails this workflow task so the worker evicts the run; the retry replays the whole history.
        raise RuntimeError("injected bug")

After the run is evicted and its history is replayed, the worker fails with [TMPRL1100]

Reproduced on version 1.34.0 and 1.37.0.

I've attached the reproduction.
_la_timeout_nde.zip

主要語言
Python
星號
1.3k
分支
305
平均合併
3 天 23 小時
30 天內合併 PR
44

環境準備

  • 沒有 Dockerfile 或 Docker Compose 檔案
  • 沒有 Pull Request 範本
  • 閱讀貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

temporalio/sdk-python 的其他 Issue

查看 temporalio/sdk-python 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。