exception documentation

class LoopError(SDKError): (source)

View In Hierarchy

Exception raised when a synchronous helper is used incorrectly with an asyncio event loop.

This error is raised when the code attempts to perform a synchronous operation (for example, calling Channel.run_sync) while the targeted asyncio event loop is already running in the current thread.

The exception subclasses SDKError so callers catching SDK-related errors will also catch this condition.

LoopError does not add any new behaviour beyond the base error; it serves only to provide a more specific error type for loop misuse.