exo-explore/exo · error · ValueError
max_buffer_size must be either an integer or math.inf
Error message
max_buffer_size must be either an integer or math.inf
What it means
Error "max_buffer_size must be either an integer or math.inf" thrown in exo-explore/exo.
Source
Thrown at src/exo/utils/channels.py:435
out.extend(self.collect())
return out
def __getstate__(self):
d = self.__dict__.copy()
d.pop("__orig_class__", None)
return d
class channel[T]: # noqa: N801
"""Create a pair of asynchronous channels for communicating within the same process"""
def __new__(
cls,
max_buffer_size: float = inf,
error_override_config: ErrorOverride | None = None,
) -> tuple[Sender[T], Receiver[T]]:
if max_buffer_size != inf and not isinstance(max_buffer_size, int):
raise ValueError("max_buffer_size must be either an integer or math.inf")
state = AnyioState[T](max_buffer_size)
return Sender(state, error_override_config), Receiver(
state, error_override_config
)
class mp_channel[T]: # noqa: N801
"""Create a pair of synchronous channels for interprocess communication"""
# max buffer size uses math.inf to represent an unbounded queue, and 0 to represent a yet unimplemented "unbuffered" queue.
def __new__(cls, max_buffer_size: float = inf) -> tuple[MpSender[T], MpReceiver[T]]:
if (
max_buffer_size == 0
or max_buffer_size != inf
and not isinstance(max_buffer_size, int)
):
raise ValueError(
"max_buffer_size must be either an integer or math.inf. 0-sized buffers are not supported by multiprocessing"View on GitHub (pinned to 21a54c5ea0)
When it happens
Trigger: Thrown at src/exo/utils/channels.py:435 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of exo-explore/exo@21a54c5ea0 (2026-08-26).
Data as JSON: /api/errors/d89288363579d751.
Report an issue: GitHub.