From 55cc04ca56fd4006dfcfc3f20a58711880f1fc5a Mon Sep 17 00:00:00 2001 From: Dmitry Patsura Date: Wed, 26 Feb 2025 12:23:36 +0100 Subject: [PATCH] chore: fmt --- packages/cubejs-backend-native/src/cross/clrepr_python.rs | 7 ++++--- packages/cubejs-backend-native/src/python/runtime.rs | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/packages/cubejs-backend-native/src/cross/clrepr_python.rs b/packages/cubejs-backend-native/src/cross/clrepr_python.rs index f984c330f9b8a..9712206845cc9 100644 --- a/packages/cubejs-backend-native/src/cross/clrepr_python.rs +++ b/packages/cubejs-backend-native/src/cross/clrepr_python.rs @@ -193,9 +193,10 @@ impl CLRepr { Ok(match self { CLRepr::Object(obj) => Self::into_py_dict_impl(obj, py)?, other => { - return Err(PyErr::new::( - "Unable to represent JsFunction in Python", - )) + return Err(PyErr::new::(format!( + "Unable to convert {:?} into PyDict", + other.kind() + ))) } }) } diff --git a/packages/cubejs-backend-native/src/python/runtime.rs b/packages/cubejs-backend-native/src/python/runtime.rs index 253536ab43402..d6d21b06677f2 100644 --- a/packages/cubejs-backend-native/src/python/runtime.rs +++ b/packages/cubejs-backend-native/src/python/runtime.rs @@ -7,7 +7,7 @@ use neon::prelude::*; use neon::types::Deferred; use once_cell::sync::OnceCell; use pyo3::prelude::*; -use pyo3::types::{PyDict, PyFunction, PyTuple}; +use pyo3::types::{PyFunction, PyTuple}; use std::fmt::Formatter; use std::future::Future; use std::pin::Pin;