zellij-org/zellij · error

Failed to create tokio runtime

Error message

Failed to create tokio runtime

What it means

Error "Failed to create tokio runtime" thrown in zellij-org/zellij.

Solutions

  1. Check system resources (threads, memory); tokio runtime creation failed at the OS level.
  2. Retry; if persistent, report with OS and resource limit details.

When it happens

Trigger: Occurs at zellij-client/src/lib.rs:102 when the operation fails: "Failed to create tokio runtime". Currently there is no defensive handling preventing or contextualizing this failure before it surfaces.

Common situations: Resource exhaustion or restrictive ulimits/namespace settings.


AI-assisted analysis of zellij-org/zellij@e839bfffa5 (2026-08-19). Data as JSON: /api/errors/4c55f99690743849. Report an issue: GitHub.

Appendix: source

Thrown at zellij-client/src/lib.rs:105

                    );
                    value
                },
                _ => {
                    let cpus = num_cpus::get_physical();
                    log::debug!(
                        "Creating client async runtime with {} tasks based on CPU count",
                        cpus
                    );
                    cpus
                },
            };
            let runtime = ASYNC_RUNTIME.get_or_init(|| {
                tokio::runtime::Builder::new_multi_thread()
                    .worker_threads(number_of_workers)
                    .thread_name("zellij client async-runtime")
                    .enable_all()
                    .build()
                    .expect("Failed to create tokio runtime")
            });
            runtime.handle().clone()
        },
    }
}

#[derive(Debug)]
pub enum RemoteClientError {
    InvalidAuthToken,
    SessionTokenExpired,
    Unauthorized,
    ConnectionFailed(String),
    UrlParseError(url::ParseError),
    IoError(std::io::Error),
    Other(Box<dyn std::error::Error + Send + Sync>),
}

impl std::fmt::Display for RemoteClientError {

View on GitHub (pinned to e839bfffa5)