cube-js/cube · error · minijinja::Error

Call error: {}

Error message

Call error: {}

What it means

The Python function was invoked successfully up to the await, but the async call itself returned an error from tokio.block_on — the Python coroutine raised, timed out, or panicked. The original error text follows the colon and identifies the failing Python code.

Source

Thrown at packages/cubejs-backend-native/src/template/mj_value/python.rs:269

            mj::Error::new(
                mj::ErrorKind::EvalBlock,
                format!("Python runtime error: {}", err),
            )
        })?;

        let call_future =
            Python::with_gil(|py| py_runtime.call_async(self.inner.clone_ref(py), arguments));

        let tokio = tokio_runtime().map_err(|err| {
            mj::Error::new(
                mj::ErrorKind::EvalBlock,
                format!("Tokio runtime error: {}", err),
            )
        })?;

        match tokio.block_on(call_future) {
            Ok(r) => Ok(to_minijinja_value(r)),
            Err(err) => Err(mj::Error::new(
                mj::ErrorKind::EvalBlock,
                format!("Call error: {}", err),
            )),
        }
    }
}

impl StructObject for JinjaPythonFunction {
    fn get_field(&self, _name: &str) -> Option<Value> {
        None
    }
}

View on GitHub (pinned to 7d981676b3)

Solutions

  1. Read the wrapped error to locate the failing Python coroutine
  2. Fix the Python function's logic, arguments, or missing dependencies
  3. Guard long-running Python work with appropriate timeouts
Defensive patterns

Strategy: try-catch

When it happens

Trigger: Thrown at packages/cubejs-backend-native/src/template/mj_value/python.rs:269 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of cube-js/cube@7d981676b3 (2026-09-02). Data as JSON: /api/errors/9de9fb0df91073cd. Report an issue: GitHub.