zellij-org/zellij · error

error attempting to wait: {}

Error message

error attempting to wait: {}

What it means

Error "error attempting to wait: {}" thrown in zellij-org/zellij.

Source

Thrown at zellij-server/src/os_input_output_unix.rs:160

    // returns the exit status, if any
    let mut should_exit = false;
    let mut attempts = 3;
    let mut signals =
        signal_hook::iterator::Signals::new(&[SIGINT, SIGTERM]).with_context(err_context)?;
    'handle_exit: loop {
        // test whether the child process has exited
        match child.try_wait() {
            Ok(Some(status)) => {
                // if the child process has exited, break outside of the loop
                // and exit this function
                // TODO: handle errors?
                break 'handle_exit Ok(status.code());
            },
            Ok(None) => {
                thread::sleep(Duration::from_millis(10));
            },
            Err(e) => panic!("error attempting to wait: {}", e),
        }

        if !should_exit {
            for signal in signals.pending() {
                if signal == SIGINT || signal == SIGTERM {
                    should_exit = true;
                }
            }
        } else if attempts > 0 {
            // let's try nicely first...
            attempts -= 1;
            kill(
                unistd::Pid::from_raw(child.id() as i32),
                Some(Signal::SIGTERM),
            )
            .with_context(err_context)?;
            continue;
        } else {

View on GitHub (pinned to 5cb5df5cce)

Solutions

  1. Check system resource limits (open files, processes) and the OS error attached to the failure.
  2. Retry the operation; if persistent, report the OS error with a zellij issue.

When it happens

Trigger: Occurs at zellij-server/src/os_input_output_unix.rs:160 when the operation fails: "error attempting to wait: {}". Currently there is no defensive handling preventing or contextualizing this failure before it surfaces.

Common situations: Typically resource exhaustion, invalid fd state, or platform-specific pty limitations.


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