You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2021/07/07 09:07:33 UTC
[GitHub] [arrow-rs] ritchie46 opened a new issue #529: master fails to compile
ritchie46 opened a new issue #529:
URL: https://github.com/apache/arrow-rs/issues/529
**Describe the bug**
Creating a new project with this `Cargo.toml` fails to compile:
```
[package]
name = "foo"
version = "0.1.0"
edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
arrow = {git = "https://github.com/apache/arrow-rs", rev = "80a57be3215ed7210971a501b10664cadfd59bea", default-features=false}
```
Output:
```
error[E0432]: unresolved import `rand::prelude::StdRng`
--> /home/ritchie46/.cargo/git/checkouts/arrow-rs-3b86e19e889d5acc/80a57be/arrow/src/util/bench_util.rs:27:5
|
27 | prelude::StdRng,
| ^^^^^^^^^^^^^^^ no `StdRng` in `prelude`
error[E0432]: unresolved import `rand::rngs::StdRng`
--> /home/ritchie46/.cargo/git/checkouts/arrow-rs-3b86e19e889d5acc/80a57be/arrow/src/util/test_util.rs:20:12
|
20 | use rand::{rngs::StdRng, Rng, SeedableRng};
| ^^^^^^^^^^^^ no `StdRng` in `rngs`
error[E0308]: mismatched types
--> /home/ritchie46/.cargo/git/checkouts/arrow-rs-3b86e19e889d5acc/80a57be/arrow/src/util/bench_util.rs:102:35
|
94 | pub fn create_string_array<Offset: StringOffsetSizeTrait>(
| ------ this type parameter
...
102 | if rng.gen::<f32>() < null_density {
| ^^^^^^^^^^^^ expected type parameter `Offset`, found `f32`
|
= note: expected type parameter `Offset`
found type `f32`
error[E0308]: mismatched types
--> /home/ritchie46/.cargo/git/checkouts/arrow-rs-3b86e19e889d5acc/80a57be/arrow/src/util/bench_util.rs:123:35
|
114 | pub fn create_binary_array<Offset: BinaryOffsetSizeTrait>(
| ------ this type parameter
...
123 | if rng.gen::<f32>() < null_density {
| ^^^^^^^^^^^^ expected type parameter `Offset`, found `f32`
|
= note: expected type parameter `Offset`
found type `f32`
error: aborting due to 4 previous errors
Some errors have detailed explanations: E0308, E0432.
For more information about an error, try `rustc --explain E0308`.
error: could not compile `arrow`
```
I think this is introduced in 80a57be3215ed7210971a501b10664cadfd59bea.
There are quite often feature tag related bugs that could be prevented if we'd run [cargo hack](https://github.com/taiki-e/cargo-hack) in CI.
Would you be willing to accept a PR that adds those checks? @alamb @jorgecarleitao @Dandandan @jhorstmann @nevi-me
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-rs] alamb commented on issue #529: master fails to compile with `default-features=false`
Posted by GitBox <gi...@apache.org>.
alamb commented on issue #529:
URL: https://github.com/apache/arrow-rs/issues/529#issuecomment-875537270
For anyone finding this ticket, a workaround is to add the following to your Cargo dependencies:
```
# ensure we get the std version of rand so arrow builds without default features
rand = { version = "0.8" }
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-rs] alamb commented on issue #529: master fails to compile with `default-features=false`
Posted by GitBox <gi...@apache.org>.
alamb commented on issue #529:
URL: https://github.com/apache/arrow-rs/issues/529#issuecomment-878375379
github got a little excited and closed this prior to the fix actually being merged
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-rs] joshuataylor edited a comment on issue #529: master fails to compile with `default-features=false`
Posted by GitBox <gi...@apache.org>.
joshuataylor edited a comment on issue #529:
URL: https://github.com/apache/arrow-rs/issues/529#issuecomment-877244562
I'm also getting this when using:
```
arrow = { git = "https://github.com/apache/arrow-rs" }
```
and also from a local path.
Adding rand does not fix this.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-rs] joshuataylor edited a comment on issue #529: master fails to compile with `default-features=false`
Posted by GitBox <gi...@apache.org>.
joshuataylor edited a comment on issue #529:
URL: https://github.com/apache/arrow-rs/issues/529#issuecomment-877244562
I'm also getting this when using:
```
arrow = { git = "https://github.com/apache/arrow-rs" }
```
and also from a local path.
Adding rand does fix this.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-rs] joshuataylor commented on issue #529: master fails to compile with `default-features=false`
Posted by GitBox <gi...@apache.org>.
joshuataylor commented on issue #529:
URL: https://github.com/apache/arrow-rs/issues/529#issuecomment-877244562
I'm also getting this when using:
```
arrow = { git = "https://github.com/apache/arrow-rs" }
```
Adding rand does not fix this.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-rs] alamb commented on issue #529: master fails to compile with `default-features=false`
Posted by GitBox <gi...@apache.org>.
alamb commented on issue #529:
URL: https://github.com/apache/arrow-rs/issues/529#issuecomment-875538550
@ritchie46 I am not sure about cargo-hack -- would the idea be to check every combination of arguments?
Note we supposedly already have a CI check for `--no-default-features` here:
https://github.com/apache/arrow-rs/blob/master/.github/workflows/rust.yml#L116
But clearly that did not catch this regression
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-rs] ritchie46 commented on issue #529: master fails to compile with `default-features=false`
Posted by GitBox <gi...@apache.org>.
ritchie46 commented on issue #529:
URL: https://github.com/apache/arrow-rs/issues/529#issuecomment-875540479
> @ritchie46 I am not sure about cargo-hack -- would the idea be to check every combination of arguments?
Indeed. Running `cargo hack check --each-feature --no-dev-deps` would run a `cargo check` on all possible feature combinations.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-rs] alamb closed issue #529: master fails to compile with `default-features=false`
Posted by GitBox <gi...@apache.org>.
alamb closed issue #529:
URL: https://github.com/apache/arrow-rs/issues/529
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-rs] alamb commented on issue #529: master fails to compile with `default-features=false`
Posted by GitBox <gi...@apache.org>.
alamb commented on issue #529:
URL: https://github.com/apache/arrow-rs/issues/529#issuecomment-877394782
I am starting to work on this one
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org