You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "Martin Tzvetanov Grigorov (Jira)" <ji...@apache.org> on 2022/01/20 18:51:00 UTC

[jira] [Commented] (AVRO-3316) [Rust] build breaks in docker build

    [ https://issues.apache.org/jira/browse/AVRO-3316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17479601#comment-17479601 ] 

Martin Tzvetanov Grigorov commented on AVRO-3316:
-------------------------------------------------

I believe this is caused by
{code:java}
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain 1.51.0 {code}
 

We run the tests against 1.51.0 (Minimum Supported Version) - [https://github.com/apache/avro/blob/68484243164666833c03336b953c63c70a247b1a/.github/workflows/test-lang-rust-ci.yml#L42]

But we run the linter only against 'stable', i.e. 1.58.0 at the moment.

 

Anyway, the test does not need to return a Result! I will improve it!

> [Rust] build breaks in docker build
> -----------------------------------
>
>                 Key: AVRO-3316
>                 URL: https://issues.apache.org/jira/browse/AVRO-3316
>             Project: Apache Avro
>          Issue Type: Bug
>          Components: rust
>            Reporter: Ryan Skraba
>            Assignee: Martin Tzvetanov Grigorov
>            Priority: Major
>
> The build with the uberjar fails with the following error:
> {code}
> $ ./build.sh docker
> ... then ...
> $ cd lang/rust && ./build.sh test
> ... then ...
> error: this function's return value is unnecessarily wrapped by `Result`
>    --> tests/io.rs:221:1
> {code}
> Complete log:
> {code:java}
> + cd lang/rust
> + ./build.sh lint test
> warning: version requirement `0.9.0+zstd.1.5.0` for dependency `zstd` includes semver metadata which will be ignored, removing the metadata is recommended to avoid confusion
>   Downloaded cpufeatures v0.2.1
>   Downloaded same-file v1.0.6
>   Downloaded tinytemplate v1.2.1
>   Downloaded termcolor v1.1.2
>   Downloaded semver v1.0.4
>   Downloaded crossbeam-channel v0.5.2
>   Downloaded unicode-width v0.1.9
>   Downloaded criterion-plot v0.4.4
>   Downloaded serde_cbor v0.11.2
>   Downloaded rayon-core v1.9.1
>   Downloaded walkdir v2.3.2
>   Downloaded md-5 v0.10.0
>   Downloaded sha2 v0.10.1
>   Downloaded humantime v2.1.0
>   Downloaded plotters-backend v0.3.2
>   Downloaded plotters-svg v0.3.1
>   Downloaded num_cpus v1.13.1
>   Downloaded hex-literal v0.3.4
>   Downloaded regex-automata v0.1.10
>   Downloaded memoffset v0.6.5
>   Downloaded bstr v0.2.17
>   Downloaded criterion v0.3.5
>   Downloaded itoa v0.4.8
>   Downloaded csv v1.1.6
>   Downloaded itertools v0.10.3
>   Downloaded half v1.8.2
>   Downloaded env_logger v0.9.0
>   Downloaded csv-core v0.1.10
>   Downloaded crossbeam-utils v0.8.6
>   Downloaded plotters v0.3.1
>   Downloaded textwrap v0.11.0
>   Downloaded scopeguard v1.1.0
>   Downloaded either v1.6.1
>   Downloaded atty v0.2.14
>   Downloaded rayon v1.5.1
>   Downloaded oorandom v11.1.3
>   Downloaded crossbeam-epoch v0.9.6
>   Downloaded crossbeam-deque v0.8.1
>   Downloaded bitflags v1.3.2
>   Downloaded clap v2.34.0
>   Downloaded cast v0.2.7
>   Downloaded rustc_version v0.4.0
>   Downloaded anyhow v1.0.52
>   Downloaded 43 crates (11.3 MB) in 0.49s (largest was `plotters` at 8.6 MB)
>    Compiling libc v0.2.112
>    Compiling proc-macro2 v1.0.36
>    Compiling autocfg v1.0.1
>    Compiling unicode-xid v0.2.2
>    Compiling syn v1.0.85
>     Checking cfg-if v1.0.0
>    Compiling serde_derive v1.0.133
>     Checking lazy_static v1.4.0
>    Compiling memchr v2.4.1
>    Compiling serde v1.0.133
>    Compiling typenum v1.15.0
>    Compiling version_check v0.9.4
>    Compiling pkg-config v0.3.24
>    Compiling crossbeam-utils v0.8.6
>    Compiling semver v1.0.4
>    Compiling crossbeam-epoch v0.9.6
>     Checking ryu v1.0.9
>    Compiling serde_json v1.0.75
>     Checking scopeguard v1.1.0
>    Compiling rayon-core v1.9.1
>     Checking regex-syntax v0.6.25
>    Compiling zstd-safe v4.1.3+zstd.1.5.1
>     Checking itoa v1.0.1
>    Compiling log v0.4.14
>    Compiling crc32fast v1.3.0
>    Compiling rustversion v1.0.6
>     Checking either v1.6.1
>     Checking regex-automata v0.1.10
>     Checking plotters-backend v0.3.2
>     Checking ppv-lite86 v0.2.16
>    Compiling unicode-segmentation v1.8.0
>     Checking rle-decode-fast v1.0.1
>    Compiling snap v1.0.5
>     Checking unicode-width v0.1.9
>     Checking same-file v1.0.6
>    Compiling anyhow v1.0.52
>     Checking byteorder v1.4.3
>     Checking bitflags v1.3.2
>     Checking half v1.8.2
>     Checking itoa v0.4.8
>     Checking adler32 v1.2.0
>     Checking termcolor v1.1.2
>     Checking cpufeatures v0.2.1
>     Checking humantime v2.1.0
>     Checking strum v0.23.0
>     Checking oorandom v11.1.3
>    Compiling hex-literal v0.3.4
>     Checking itertools v0.10.3
>     Checking libflate_lz77 v1.1.0
>     Checking textwrap v0.11.0
>     Checking walkdir v2.3.2
>    Compiling generic-array v0.14.5
>     Checking plotters-svg v0.3.1
>    Compiling memoffset v0.6.5
>    Compiling num-traits v0.2.14
>    Compiling num-integer v0.1.44
>    Compiling rayon v1.5.1
>    Compiling num-bigint v0.4.3
>    Compiling heck v0.3.3
>     Checking clap v2.34.0
>     Checking crossbeam-channel v0.5.2
>    Compiling rustc_version v0.4.0
>     Checking libflate v1.1.1
>     Checking aho-corasick v0.7.18
>     Checking csv-core v0.1.10
>    Compiling quote v1.0.14
>     Checking getrandom v0.2.4
>     Checking num_cpus v1.13.1
>     Checking atty v0.2.14
>    Compiling jobserver v0.1.24
>     Checking rand_core v0.6.3
>    Compiling cast v0.2.7
>     Checking crossbeam-deque v0.8.1
>    Compiling cc v1.0.72
>     Checking rand_chacha v0.3.1
>     Checking rand v0.8.4
>     Checking block-buffer v0.10.0
>     Checking crypto-common v0.1.1
>     Checking digest v0.10.1
>     Checking criterion-plot v0.4.4
>     Checking regex v1.5.4
>     Checking plotters v0.3.1
>     Checking sha2 v0.10.1
>     Checking md-5 v0.10.0
>    Compiling zstd-sys v1.6.2+zstd.1.5.1
>    Compiling bzip2-sys v0.1.11+1.0.8
>    Compiling lzma-sys v0.1.17
>     Checking env_logger v0.9.0
>     Checking bzip2 v0.4.3
>    Compiling synstructure v0.12.6
>     Checking xz2 v0.1.6
>    Compiling zerocopy-derive v0.3.1
>    Compiling thiserror-impl v1.0.30
>    Compiling strum_macros v0.23.1
>    Compiling typed-builder v0.9.1
>     Checking zerocopy v0.6.1
>     Checking thiserror v1.0.30
>     Checking zstd v0.9.2+zstd.1.5.1
>     Checking bstr v0.2.17
>     Checking uuid v0.8.2
>     Checking serde_cbor v0.11.2
>     Checking csv v1.1.6
>     Checking tinytemplate v1.2.1
>     Checking avro-rs v0.14.0 (/home/ryan.skraba/avro/lang/rust)
>     Checking criterion v0.3.5
> error: this function's return value is unnecessarily wrapped by `Result`
>    --> tests/io.rs:221:1
>     |
> 221 | / fn test_no_default_value() -> Result<(), Error> {
> 222 | |     let reader_schema = Schema::parse_str(
> 223 | |         r#"{
> 224 | |             "type": "record",
> ...   |
> 239 | |     Ok(())
> 240 | | }
>     | |_^
>     |
>     = note: `-D clippy::unnecessary-wraps` implied by `-D clippy::all`
>     = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_wraps
> help: remove `Result` from the return type...
>     |
> 221 | fn test_no_default_value() -> () {
>     |                               ^^
> help: ...and change the returning expressions
>     |
> 239 |     ()
>     |error: aborting due to previous errorerror: could not compile `avro-rs`To learn more, run the command again with --verbose.
> warning: build failed, waiting for other jobs to finish...
> error: build failed
>  {code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)