smol-rs / async-channel

Async multi-producer multi-consumer channel
Apache License 2.0
752 stars 39 forks source link

Tests mpmc_stream and mpmc fails on s390x: assertion `left == right` failed #99

Open jonassmedegaard opened 1 month ago

jonassmedegaard commented 1 month ago

Building crate async-channel v2.3.1 fails tests mpmc_stream and mpmc on s390x, like this:

Running `CARGO=/usr/bin/cargo CARGO_MANIFEST_DIR=/usr/share/cargo/registry/async-channel-2.3.1 CARGO_PKG_AUTHORS='Stjepan Glavina <stjepang@gmail.com>' CARGO_PKG_DESCRIPTION='Async multi-producer multi-consumer channel' CARGO_PKG_HOMEPAGE='' CARGO_PKG_LICENSE='Apache-2.0 OR MIT' CARGO_PKG_LICENSE_FILE='' CARGO_PKG_NAME=async-channel CARGO_PKG_README=README.md CARGO_PKG_REPOSITORY='https://github.com/smol-rs/async-channel' CARGO_PKG_RUST_VERSION=1.60 CARGO_PKG_VERSION=2.3.1 CARGO_PKG_VERSION_MAJOR=2 CARGO_PKG_VERSION_MINOR=3 CARGO_PKG_VERSION_PATCH=1 CARGO_PKG_VERSION_PRE='' LD_LIBRARY_PATH='/tmp/tmp.5edrX768DR/target/s390x-unknown-linux-gnu/release/deps:/tmp/tmp.5edrX768DR/target/s390x-unknown-linux-gnu/release:/usr/lib/rustlib/s390x-unknown-linux-gnu/lib' /tmp/tmp.5edrX768DR/target/s390x-unknown-linux-gnu/release/deps/bounded-9d69132e446b210a`
104s 
104s running 22 tests
104s test capacity ... ok
104s test len_empty_full ... ok
104s test receiver_count ... ok
104s test recv_after_close ... ok
104s test len ... ok
104s test send_after_close ... ok
104s test sender_count ... ok
104s test smoke ... ok
104s test smoke_blocking ... ok
104s test mpmc_stream ... FAILED
105s test mpmc ... FAILED
105s test spsc ... ok
105s test weak ... ok
105s test forget_blocked_sender ... ok
105s test forget_blocked_receiver ... ok
105s test close_wakes_sender ... ok
105s test close_wakes_receiver ... ok
106s test try_recv ... ok
107s test try_send ... ok
107s test force_send ... ok
108s test recv ... ok
108s test send ... ok
108s 
108s failures:
108s 
108s ---- mpmc_stream stdout ----
108s thread 'mpmc_stream' panicked at tests/bounded.rs:501:9:
108s assertion `left == right` failed
108s   left: 3
108s  right: 4
108s stack backtrace:
108s    0: rust_begin_unwind
108s    1: core::panicking::panic_fmt
108s    2: core::panicking::assert_failed_inner
108s    3: core::panicking::assert_failed
108s    4: core::ops::function::FnOnce::call_once
108s note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
108s 
108s ---- mpmc stdout ----
108s thread 'mpmc' panicked at tests/bounded.rs:468:9:
108s assertion `left == right` failed
108s   left: 5
108s  right: 4
108s stack backtrace:
108s    0: rust_begin_unwind
108s    1: core::panicking::panic_fmt
108s    2: core::panicking::assert_failed_inner
108s    3: core::panicking::assert_failed
108s    4: core::ops::function::FnOnce::call_once
108s note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
108s 
108s 
108s failures:
108s     mpmc
108s     mpmc_stream
108s 
108s test result: FAILED. 20 passed; 2 failed; 0 ignored; 0 measured; 0 filtered out; finished in 3.50s

Full build log

Curiously, a previous build from virtually identical source (only change was specific to armel) succeeded. The build environment had changed slightly: systemd 256.2 -> 256-4 libc6 2.38 -> 2.39 linux-libc-dev 6.9.9 -> 6.9.10

Perhaps this is related to #78 - except here the failure has persisted in 5 contiguous rebuilds.

jonassmedegaard commented 1 month ago

Another curious detail: The tests succeed with --no-default-features.