Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix default arrow build #533

Merged
merged 2 commits into from
Jul 12, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions arrow-pyarrow-integration-testing/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@ name = "arrow_pyarrow_integration_testing"
crate-type = ["cdylib"]

[dependencies]
# ensure we get the std version of rand so arrow builds without default features
rand = { version = "0.8" }
arrow = { path = "../arrow", version = "5.0.0-SNAPSHOT" }
pyo3 = { version = "0.12.1", features = ["extension-module"] }

Expand Down
5 changes: 4 additions & 1 deletion arrow/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,15 @@ multiversion = "0.6.1"
bitflags = "1.2.1"

[features]
default = ["csv", "ipc"]
default = ["csv", "ipc", "test_utils"]
avx512 = []
csv = ["csv_crate"]
ipc = ["flatbuffers"]
simd = ["packed_simd"]
prettyprint = ["prettytable-rs"]
# The test utils feature enables code used in benchmarks and tests but
# not the core arrow code itself
test_utils = ["rand/std", "rand/std_rng"]
# this is only intended to be used in single-threaded programs: it verifies that
# all allocated memory is being released (no memory leaks).
# See README for details
Expand Down
2 changes: 1 addition & 1 deletion arrow/src/util/bit_util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ where
simd_result.write_to_slice_unaligned_unchecked(result);
}

#[cfg(test)]
#[cfg(all(test, feature = "test_utils"))]
mod tests {
use std::collections::HashSet;

Expand Down
4 changes: 4 additions & 0 deletions arrow/src/util/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,20 @@
// specific language governing permissions and limitations
// under the License.

#[cfg(feature = "test_utils")]
pub mod bench_util;
pub mod bit_chunk_iterator;
pub mod bit_util;
#[cfg(feature = "test_utils")]
pub mod data_gen;
pub mod display;
#[cfg(feature = "test_utils")]
pub mod integration_util;
#[cfg(feature = "prettyprint")]
pub mod pretty;
pub(crate) mod serialization;
pub mod string_writer;
#[cfg(feature = "test_utils")]
pub mod test_util;

mod trusted_len;
Expand Down
3 changes: 0 additions & 3 deletions arrow/test/dependency/default-features/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,4 @@ edition = "2018"
[dependencies]
arrow = { path = "../../../../arrow", version = "5.0.0-SNAPSHOT" }

# Workaround for https://github.com/apache/arrow-rs/issues/529
rand = { version = "0.8" }

[workspace]
3 changes: 0 additions & 3 deletions arrow/test/dependency/no-default-features/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,4 @@ edition = "2018"
[dependencies]
arrow = { path = "../../../../arrow", version = "5.0.0-SNAPSHOT", default-features = false }

# Workaround for https://github.com/apache/arrow-rs/issues/529
rand = { version = "0.8" }

[workspace]