From 30e0d43ccb7f358708cbff5b79730f7949c9d21b Mon Sep 17 00:00:00 2001 From: Jeremy Dyer Date: Thu, 4 May 2023 10:13:45 -0400 Subject: [PATCH 1/2] Add and to DataTypeMap --- src/common/data_type.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/common/data_type.rs b/src/common/data_type.rs index a7b79f49f..6f1d8748b 100644 --- a/src/common/data_type.rs +++ b/src/common/data_type.rs @@ -33,12 +33,12 @@ use crate::errors::py_datafusion_err; #[derive(Debug, Clone)] #[pyclass(name = "DataTypeMap", module = "datafusion.common", subclass)] pub struct DataTypeMap { - #[allow(dead_code)] - arrow_type: PyDataType, - #[allow(dead_code)] - python_type: PythonType, - #[allow(dead_code)] - sql_type: SqlType, + #[pyo3(get, set)] + pub arrow_type: PyDataType, + #[pyo3(get, set)] + pub python_type: PythonType, + #[pyo3(get, set)] + pub sql_type: SqlType, } impl DataTypeMap { From 011e83894c204228c44fdea632145cce205f226e Mon Sep 17 00:00:00 2001 From: Jeremy Dyer Date: Thu, 4 May 2023 10:18:14 -0400 Subject: [PATCH 2/2] Add PyDataType as pub --- src/common/data_type.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/common/data_type.rs b/src/common/data_type.rs index 6f1d8748b..a9b0d17d5 100644 --- a/src/common/data_type.rs +++ b/src/common/data_type.rs @@ -421,7 +421,7 @@ impl DataTypeMap { #[derive(Debug, Clone, PartialEq, Eq, Hash, PartialOrd, Ord)] #[pyclass(name = "DataType", module = "datafusion.common")] pub struct PyDataType { - data_type: DataType, + pub data_type: DataType, } impl From for DataType {