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

Abierto
#2,183 0 comentarios 0 reacciones 1 asignado Ver en GitHub

Los mantenedores suelen responder en 1 día

@mjameswh ya está trabajando en esto.

Desde el 2/12/2026.

Evaluación

Este issue todavía no se ha evaluado.

Descripción

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

Lenguaje dominante
Python
Estrellas
1.3k
Forks
305
Merge medio
3 d 23 h
PR fusionados (30 d)
44

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de temporalio/sdk-python

Todos los issues de temporalio/sdk-python

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.