Skip to content

Commit

Permalink
fix doc test
Browse files Browse the repository at this point in the history
  • Loading branch information
jimexist committed Feb 6, 2022
1 parent 7cbbd5a commit 1b63a6b
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 10 deletions.
2 changes: 2 additions & 0 deletions datafusion-common/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
mod column;
mod dfschema;
mod error;
#[cfg(feature = "pyarrow")]
mod pyarrow;
mod scalar;

pub use column::Column;
Expand Down
12 changes: 6 additions & 6 deletions datafusion/src/pyarrow.rs → datafusion-common/src/pyarrow.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,13 @@
// specific language governing permissions and limitations
// under the License.

use pyo3::prelude::*;
use pyo3::types::PyList;
//! PyArrow

use crate::arrow::array::ArrayData;
use crate::arrow::pyarrow::PyArrowConvert;
use crate::scalar::ScalarValue;
use crate::ScalarValue;
use arrow::array::ArrayData;
use arrow::pyarrow::PyArrowConvert;
use pyo3::types::PyList;
use pyo3::{FromPyObject, IntoPy, PyAny, PyObject, PyResult, Python};

impl PyArrowConvert for ScalarValue {
fn from_pyarrow(value: &PyAny) -> PyResult<Self> {
Expand Down Expand Up @@ -68,7 +69,6 @@ mod tests {
use pyo3::prepare_freethreaded_python;
use pyo3::py_run;
use pyo3::types::PyDict;
use pyo3::Python;

fn init_python() {
prepare_freethreaded_python();
Expand Down
2 changes: 1 addition & 1 deletion datafusion-common/src/scalar.rs
Original file line number Diff line number Diff line change
Expand Up @@ -665,7 +665,7 @@ impl ScalarValue {
///
/// Example
/// ```
/// use datafusion::scalar::ScalarValue;
/// use datafusion_common::ScalarValue;
/// use arrow::array::{ArrayRef, BooleanArray};
///
/// let scalars = vec![
Expand Down
3 changes: 0 additions & 3 deletions datafusion/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -224,9 +224,6 @@ pub use parquet;

pub(crate) mod field_util;

#[cfg(feature = "pyarrow")]
mod pyarrow;

pub mod from_slice;

#[cfg(test)]
Expand Down

0 comments on commit 1b63a6b

Please sign in to comment.