Skip to content

Commit

Permalink
Merge branch 'main' into prerelease
Browse files Browse the repository at this point in the history
  • Loading branch information
wangxiaoying committed Sep 8, 2023
2 parents 8347fd0 + 3075e5f commit f268e71
Show file tree
Hide file tree
Showing 11 changed files with 28 additions and 27 deletions.
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion connectorx-cpp/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "connectorx-cpp"
version = "0.3.2"
version = "0.3.3-alpha.1"
edition = "2021"
license = "MIT"

Expand Down
24 changes: 12 additions & 12 deletions connectorx-python/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions connectorx-python/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
authors = ["Weiyuan Wu <[email protected]>"]
edition = "2018"
name = "connectorx-python"
version = "0.3.2"
version = "0.3.3-alpha.1"
license = "MIT"
readme = "README.md"

Expand All @@ -27,12 +27,12 @@ lazy_static = "1.4.0"
libc = "0.2"
log = "0.4"
ndarray = "0.15"
numpy = "0.14"
numpy = "0.15"
openssl = {version = "0.10", features = ["vendored"]}
postgres = {version = "0.19", features = ["with-chrono-0_4", "with-uuid-0_8", "with-serde_json-1"]}
postgres-native-tls = {version = "0.5"}
postgres-openssl = {version = "0.5.0"}
pyo3 = {version = "0.14", default-features = false, features = ["macros"]}
pyo3 = {version = "0.15", default-features = false, features = ["macros"]}
pyo3-built = "0.4"
rust_decimal = {version = "1", features = ["db-postgres"]}
serde_json = "1"
Expand Down
3 changes: 2 additions & 1 deletion connectorx-python/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,13 @@ license = "MIT"
maintainers = ["Weiyuan Wu <[email protected]>"]
name = "connectorx"
readme = "README.md" # Markdown files are supported
version = "0.3.2"
version = "0.3.3-alpha.1"

[project]
name = "connectorx" # Target file name of maturin build
readme = "README.md"
license = { text = "MIT" }
requires-python = ">=3.8"

[tool.poetry.dependencies]
dask = {version = "^2021", optional = true, extras = ["dataframe"]}
Expand Down
2 changes: 1 addition & 1 deletion connectorx-python/src/pandas/pandas_columns/array.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use std::marker::PhantomData;
pub struct PyList(Py<pyo3::types::PyList>);

// In order to put it into a numpy array
impl Element for PyList {
unsafe impl Element for PyList {
const DATA_TYPE: numpy::DataType = numpy::DataType::Object;
fn is_same_type(dtype: &PyArrayDescr) -> bool {
unsafe { *dtype.as_dtype_ptr() }.type_num == NPY_TYPES::NPY_OBJECT as i32
Expand Down
4 changes: 2 additions & 2 deletions connectorx-python/src/pandas/pandas_columns/boolean.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ impl<'a> FromPyObject<'a> for BooleanBlock<'a> {
} else {
// if extension array
let tuple = ob.downcast::<PyTuple>()?;
let data = tuple.get_item(0);
let mask = tuple.get_item(1);
let data = tuple.get_item(0)?;
let mask = tuple.get_item(1)?;
check_dtype(data, "bool")?;
check_dtype(mask, "bool")?;

Expand Down
2 changes: 1 addition & 1 deletion connectorx-python/src/pandas/pandas_columns/bytes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ use std::any::TypeId;
pub struct PyBytes(Py<pyo3::types::PyBytes>);

// In order to put it into a numpy array
impl Element for PyBytes {
unsafe impl Element for PyBytes {
const DATA_TYPE: numpy::DataType = numpy::DataType::Object;
fn is_same_type(dtype: &PyArrayDescr) -> bool {
unsafe { *dtype.as_dtype_ptr() }.type_num == NPY_TYPES::NPY_OBJECT as i32
Expand Down
4 changes: 2 additions & 2 deletions connectorx-python/src/pandas/pandas_columns/int64.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ impl<'a> FromPyObject<'a> for Int64Block<'a> {
Ok(Int64Block::NumPy(data))
} else {
let tuple = ob.downcast::<PyTuple>()?;
let data = tuple.get_item(0);
let mask = tuple.get_item(1);
let data = tuple.get_item(0)?;
let mask = tuple.get_item(1)?;
check_dtype(data, "int64")?;
check_dtype(mask, "bool")?;

Expand Down
2 changes: 1 addition & 1 deletion connectorx-python/src/pandas/pystring.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use std::str::from_utf8_unchecked;
pub struct PyString(Py<pyo3::types::PyString>);

// In order to put it into a numpy array
impl Element for PyString {
unsafe impl Element for PyString {
const DATA_TYPE: numpy::DataType = numpy::DataType::Object;
fn is_same_type(dtype: &PyArrayDescr) -> bool {
unsafe { *dtype.as_dtype_ptr() }.type_num == NPY_TYPES::NPY_OBJECT as i32
Expand Down
2 changes: 1 addition & 1 deletion connectorx/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ license = "MIT"
name = "connectorx"
readme = "../README.md"
repository = "https://github.com/sfu-db/connector-x"
version = "0.3.2"
version = "0.3.3-alpha.1"

[dependencies]
anyhow = "1"
Expand Down

0 comments on commit f268e71

Please sign in to comment.