Skip to content

Commit 866f5a5

Browse files
committed
Return list instead of tuple for iterated arrays
Ensures mutable sequence semantics when handling array results in the JMESPath runtime.
1 parent 359c9c2 commit 866f5a5

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

omlish/specs/jmespath/runtime.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ def array_items(self, value: ta.Any) -> ta.Sequence[ta.Any]:
107107
items = self.iter_array_or_raise(value)
108108
if isinstance(items, ta.Sequence):
109109
return items
110-
return tuple(items)
110+
return list(items)
111111

112112
@abc.abstractmethod
113113
def iter_object_values(self, value: ta.Any) -> ta.Iterable[ta.Any] | None:

0 commit comments

Comments
 (0)