We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8fd7786 commit 58afd22Copy full SHA for 58afd22
temporalio/converter.py
@@ -15,6 +15,7 @@
15
from dataclasses import dataclass
16
from datetime import datetime
17
from enum import IntEnum
18
+from itertools import zip_longest
19
from typing import (
20
Any,
21
Awaitable,
@@ -291,10 +292,9 @@ def from_payloads(
291
292
RuntimeError: Error during decode
293
"""
294
values = []
- for index, payload in enumerate(payloads):
295
- type_hint = None
296
- if type_hints and len(type_hints) > index:
297
- type_hint = type_hints[index]
+ for index, (payload, type_hint) in enumerate(
+ zip_longest(payloads, type_hints or [])
+ ):
298
# Raw value should just wrap
299
if type_hint == temporalio.common.RawValue:
300
values.append(temporalio.common.RawValue(payload))
0 commit comments