Skip to content

Panic - Future still here when dropping #2278

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

Closed
AgeManning opened this issue Dec 7, 2020 · 6 comments
Closed

Panic - Future still here when dropping #2278

AgeManning opened this issue Dec 7, 2020 · 6 comments
Labels
A-stream Area: futures::stream

Comments

@AgeManning
Copy link

AgeManning commented Dec 7, 2020

Hey all,

A user has experienced a panic. The exact state of the application is not known, however it appears there is an unexpected panic in the FuturesUnordered struct. It appears they are hitting this "bomb"

// Consequently it *should* be the case that we always drop futures from
// the `FuturesUnordered` instance. This is a bomb, just in case there's
// a bug in that logic.
which would indicate some logic error.

Here is the provided backtrace

thread 'tokio-runtime-worker' panicked at 'future still here when dropping', /cargo/registry/src/github.com-1ecc6299db9ec823/futures-util-0.3.8/src/stream/futures_unordered/abort.rs:11:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
thread 'tokio-runtime-worker' panicked at 'panicking twice to abort the program', /cargo/registry/src/github.com-1ecc6299db9ec823/futures-util-0.3.8/src/stream/futures_unordered/abort.rs:6:13
stack backtrace:
   0:     0x563c1d8449e0 - std::backtrace_rs::backtrace::libunwind::trace::h577ea05e9ca4629a
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/../../backtrace/src/backtrace/libunwind.rs:96
   1:     0x563c1d8449e0 - std::backtrace_rs::backtrace::trace_unsynchronized::h50b9b72b84c7dd56
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/../../backtrace/src/backtrace/mod.rs:66
   2:     0x563c1d8449e0 - std::sys_common::backtrace::_print_fmt::h6541cf9823837fac
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/sys_common/backtrace.rs:79
   3:     0x563c1d8449e0 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::hf64fbff071026df5
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/sys_common/backtrace.rs:58
   4:     0x563c1d86a1fc - core::fmt::write::h9ddafa4860d8adff
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/core/src/fmt/mod.rs:1082
   5:     0x563c1d83c167 - std::io::Write::write_fmt::h1d2ee292d2b65481
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/io/mod.rs:1514
   6:     0x563c1d847190 - std::sys_common::backtrace::_print::ha25f9ff5080d886d
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/sys_common/backtrace.rs:61
   7:     0x563c1d847190 - std::sys_common::backtrace::print::h213e8aa8dc5405c0
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/sys_common/backtrace.rs:48
   8:     0x563c1d847190 - std::panicking::default_hook::{{closure}}::h6482fae49ef9d963
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/panicking.rs:200
   9:     0x563c1d846edc - std::panicking::default_hook::he30ad7589e0970f9
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/panicking.rs:219
  10:     0x563c1d8477f3 - std::panicking::rust_panic_with_hook::haa1ed36ada4ffb03
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/panicking.rs:569
  11:     0x563c1d4a5d44 - std::panicking::begin_panic::{{closure}}::h3129100e5dcd1a95
  12:     0x563c1d4a5d1c - std::sys_common::backtrace::__rust_end_short_backtrace::h8e3108636f7dc442
  13:     0x563c1d4a5c6c - std::panicking::begin_panic::h563b6e30158033e7
  14:     0x563c1d4a5c39 - <futures_util::stream::futures_unordered::abort::abort::DoublePanic as core::ops::drop::Drop>::drop::h4ae5ebe2e6254e92
  15:     0x563c1d4a5ba7 - core::ptr::drop_in_place::hf8282f6f6282e443
  16:     0x563c1d4a5c1e - futures_util::stream::futures_unordered::abort::abort::h387364437e9f6150
  17:     0x563c1cac2458 - alloc::sync::Arc<T>::drop_slow::h6f7325f7ea6b0a8f
  18:     0x563c1c19a749 - futures_task::waker::drop_arc_raw::h1011981eb8e5dd09
  19:     0x563c1cf16537 - alloc::sync::Arc<T>::drop_slow::h034a37d14942ad66
  20:     0x563c1cf0358d - core::ptr::drop_in_place::h2c70017680f0de9a
  21:     0x563c1cf03f3c - core::ptr::drop_in_place::hd5665fe93db9ea4f
  22:     0x563c1cac1f94 - alloc::sync::Arc<T>::drop_slow::h6cd19f8b610f1267
  23:     0x563c1c3e5fe5 - core::ptr::drop_in_place::h53564196ac62d43f
  24:     0x563c1c3faa83 - core::ptr::drop_in_place::hb772663b1eb3ec8d
  25:     0x563c1c3d381c - core::ptr::drop_in_place::h07b7b117b05e40c1
  26:     0x563c1c3ed75d - core::ptr::drop_in_place::h7c62f27a2445f8bc
  27:     0x563c1c3774b3 - <libp2p_core::connection::manager::task::Task<F,M,H,I,O,E> as core::future::future::Future>::poll::h3c4b8a6339a28abb
  28:     0x563c1ceadc7b - tokio::runtime::handle::Handle::enter::hd26eacbf130d9886
  29:     0x563c1ced9f4a - <futures_util::future::select::Select<A,B> as core::future::future::Future>::poll::hbf03338d8e85248f
  30:     0x563c1ce9fa46 - <futures_util::future::future::map::Map<Fut,F> as core::future::future::Future>::poll::hfbbf3e67de26f8a2
  31:     0x563c1ce7d4d1 - <futures_util::future::future::flatten::Flatten<Fut,<Fut as core::future::future::Future>::Output> as core::future::future::Future>::poll::ha0acc3729a79e574
  32:     0x563c1ceed3dd - <std::panic::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::h4758cbd6597e0484
  33:     0x563c1ceacc0c - tokio::runtime::task::harness::Harness<T,S>::poll::h3c03e6b7a19198fe
  34:     0x563c1d3b4934 - std::thread::local::LocalKey<T>::with::ha0f5f4c2439f329b
  35:     0x563c1d3d824e - tokio::runtime::thread_pool::worker::Context::run_task::h9ca01fbeb7bfefcc
  36:     0x563c1d3d73e0 - tokio::runtime::thread_pool::worker::Context::run::h6f02d519c2949342
  37:     0x563c1d3c7723 - tokio::macros::scoped_tls::ScopedKey<T>::set::h695d36504f5d390c
  38:     0x563c1d3d6e59 - tokio::runtime::thread_pool::worker::run::h34b0ab6a660b1fcf
  39:     0x563c1d3cf436 - tokio::loom::std::unsafe_cell::UnsafeCell<T>::with_mut::hf2e66298b82890e6
  40:     0x563c1d3df242 - tokio::runtime::task::harness::Harness<T,S>::poll::hebb35df369eff3a3
  41:     0x563c1d3c9f69 - tokio::runtime::blocking::pool::Inner::run::h34faf12e1db9f844
  42:     0x563c1d3b4552 - std::sys_common::backtrace::__rust_begin_short_backtrace::h207a11dbaec6c57a
  43:     0x563c1d3c27fc - core::ops::function::FnOnce::call_once{{vtable.shim}}::h73f7feeaf931bc04
  44:     0x563c1d84ca4a - <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once::h670c50864ac2cb92
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/alloc/src/boxed.rs:1042
  45:     0x563c1d84ca4a - <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once::h2511952749086d81
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/alloc/src/boxed.rs:1042
  46:     0x563c1d84ca4a - std::sys::unix::thread::Thread::new::thread_start::h5ad4ddffe24373a8
                               at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/sys/unix/thread.rs:87
  47:     0x7f6ef741c609 - start_thread
  48:     0x7f6ef7328293 - clone
  49:                0x0 - <unknown>
thread panicked while panicking. aborting.
@thomaseizinger
Copy link
Contributor

The last line seems pretty interesting:

thread panicked while panicking. aborting.

@taiki-e
Copy link
Member

taiki-e commented Dec 7, 2020

Could you provide code to reproduce this issue?


The last line seems pretty interesting:

thread panicked while panicking. aborting.

Double panic will be converted to abort. By using this mechanism, you can use the same functionality as unstable intrinsics::abort in no-std environment.

@AgeManning
Copy link
Author

Unfortunately I can't provide code to reproduce this.

This was reported by one of our users. The backtrace wasn't sufficient to isolate the exact code path and I've not seen this occur before apart from this. :(

@taiki-e taiki-e added the A-stream Area: futures::stream label Dec 17, 2020
@mbuesch
Copy link

mbuesch commented Apr 29, 2021

Hi,

I also experience this strange crash and I'm kind of lost.
I'm not sure whether this is a problem in my code, the stick crate I'm using, the futures crate, or anything else that stick depends on.

This is the stripped down code I use to reproduce the behaviour:

sticktest.tar.gz

If I run the executable and then plug an USB joystick into my machine (which causes the listener future to become ready), then the following crash happens:

    Finished dev [unoptimized + debuginfo] target(s) in 0.03s
     Running `target/debug/sticktest`
Main loop
Async loop
Awaiting listener
Stalled.
Main loop
Stalled.
Main loop
Stalled.
Main loop
Stalled.
Main loop
Stalled.
Main loop
Stalled.
Main loop
Stalled.
thread '<unnamed>' panicked at 'future still here when dropping', /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-util-0.3.14/src/stream/futures_unordered/abort.rs:11:5
stack backtrace:
   0: rust_begin_unwind
             at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panicking.rs:493:5
   1: std::panicking::begin_panic_fmt
             at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panicking.rs:435:5
   2: futures_util::stream::futures_unordered::abort::abort
             at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-util-0.3.14/src/stream/futures_unordered/abort.rs:11:5
   3: <futures_util::stream::futures_unordered::task::Task<Fut> as core::ops::drop::Drop>::drop
             at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-util-0.3.14/src/stream/futures_unordered/task.rs:114:17
   4: core::ptr::drop_in_place<futures_util::stream::futures_unordered::task::Task<futures_task::future_obj::LocalFutureObj<()>>>
             at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/ptr/mod.rs:179:1
   5: alloc::sync::Arc<T>::drop_slow
             at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/alloc/src/sync.rs:1039:18
   6: <alloc::sync::Arc<T> as core::ops::drop::Drop>::drop
             at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/alloc/src/sync.rs:1571:13
   7: core::ptr::drop_in_place<alloc::sync::Arc<futures_util::stream::futures_unordered::task::Task<futures_task::future_obj::LocalFutureObj<()>>>>
             at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/ptr/mod.rs:179:1
   8: futures_task::arc_wake::ArcWake::wake
             at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-task-0.3.14/src/arc_wake.rs:33:5
   9: futures_task::waker::wake_arc_raw
             at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-task-0.3.14/src/waker.rs:49:5
  10: core::task::wake::Waker::wake
             at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/task/wake.rs:217:18
  11: smelling_salts::device::hardware_thread
             at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/smelling_salts-0.1.0/src/device.rs:195:13
  12: smelling_salts::device::Device::new::{{closure}}::{{closure}}
             at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/smelling_salts-0.1.0/src/device.rs:287:47
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
thread '<unnamed>' panicked at 'panicking twice to abort the program', /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-util-0.3.14/src/stream/futures_unordered/abort.rs:6:13
stack backtrace:
   0:     0x55e5cd2c30d0 - std::backtrace_rs::backtrace::libunwind::trace::h5e9d00f0cdf4f57e
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/../../backtrace/src/backtrace/libunwind.rs:90:5
   1:     0x55e5cd2c30d0 - std::backtrace_rs::backtrace::trace_unsynchronized::hd5302bd66215dab9
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:     0x55e5cd2c30d0 - std::sys_common::backtrace::_print_fmt::ha0237cd11a34e2bf
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/sys_common/backtrace.rs:67:5
   3:     0x55e5cd2c30d0 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h171d4c10df1a98ee
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/sys_common/backtrace.rs:46:22
   4:     0x55e5cd2daefc - core::fmt::write::h89e4288724daa3fa
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/fmt/mod.rs:1096:17
   5:     0x55e5cd2c0e22 - std::io::Write::write_fmt::h6d40f996e84584d9
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/io/mod.rs:1568:15
   6:     0x55e5cd2c5225 - std::sys_common::backtrace::_print::h0c0b93221682afc8
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/sys_common/backtrace.rs:49:5
   7:     0x55e5cd2c5225 - std::sys_common::backtrace::print::h57a9f95204c2fdd6
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/sys_common/backtrace.rs:36:9
   8:     0x55e5cd2c5225 - std::panicking::default_hook::{{closure}}::h4245258b50e37e69
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panicking.rs:208:50
   9:     0x55e5cd2c4d83 - std::panicking::default_hook::h7b00dcc1d0944747
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panicking.rs:225:9
  10:     0x55e5cd2c59c1 - std::panicking::rust_panic_with_hook::h71e6a073d87de1f5
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panicking.rs:591:17
  11:     0x55e5cd2a3c5e - std::panicking::begin_panic::{{closure}}::h567d42d4b7d6f389
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panicking.rs:520:9
  12:     0x55e5cd2a49a9 - std::sys_common::backtrace::__rust_end_short_backtrace::he73ac0c3d06915bd
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/sys_common/backtrace.rs:141:18
  13:     0x55e5cd2a3b8b - std::panicking::begin_panic::hbf38bdd99f2601b0
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panicking.rs:519:12
  14:     0x55e5cd2a4021 - <futures_util::stream::futures_unordered::abort::abort::DoublePanic as core::ops::drop::Drop>::drop::h143c76fdd6356051
                               at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-util-0.3.14/src/stream/futures_unordered/abort.rs:6:13
  15:     0x55e5cd2a4bbf - core::ptr::drop_in_place<futures_util::stream::futures_unordered::abort::abort::DoublePanic>::hdb330efae88ca3f3
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/ptr/mod.rs:179:1
  16:     0x55e5cd2a3fd4 - futures_util::stream::futures_unordered::abort::abort::h16521318c62c3f11
                               at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-util-0.3.14/src/stream/futures_unordered/abort.rs:12:1
  17:     0x55e5cd2a6652 - <futures_util::stream::futures_unordered::task::Task<Fut> as core::ops::drop::Drop>::drop::heb955675f88b1ee8
                               at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-util-0.3.14/src/stream/futures_unordered/task.rs:114:17
  18:     0x55e5cd2a4a76 - core::ptr::drop_in_place<futures_util::stream::futures_unordered::task::Task<futures_task::future_obj::LocalFutureObj<()>>>::h4e0d048604f43dba
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/ptr/mod.rs:179:1
  19:     0x55e5cd2a34c4 - alloc::sync::Arc<T>::drop_slow::h8863a3d3bde8e22b
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/alloc/src/sync.rs:1039:18
  20:     0x55e5cd2a368f - <alloc::sync::Arc<T> as core::ops::drop::Drop>::drop::h99d5161aafa9d67e
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/alloc/src/sync.rs:1571:13
  21:     0x55e5cd2a4aff - core::ptr::drop_in_place<alloc::sync::Arc<futures_util::stream::futures_unordered::task::Task<futures_task::future_obj::LocalFutureObj<()>>>>::hcee29c2123408ee2
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/ptr/mod.rs:179:1
  22:     0x55e5cd2972af - futures_task::arc_wake::ArcWake::wake::h8b3fd84e12546c2c
                               at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-task-0.3.14/src/arc_wake.rs:33:5
  23:     0x55e5cd297a02 - futures_task::waker::wake_arc_raw::h61b3bfe43a2a1c1d
                               at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/futures-task-0.3.14/src/waker.rs:49:5
  24:     0x55e5cd28cd0b - core::task::wake::Waker::wake::h2785e3bbde62c13f
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/task/wake.rs:217:18
  25:     0x55e5cd28a42d - smelling_salts::device::hardware_thread::hdeaf09da9edb7d56
                               at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/smelling_salts-0.1.0/src/device.rs:195:13
  26:     0x55e5cd28abea - smelling_salts::device::Device::new::{{closure}}::{{closure}}::h9de8669975c6fb86
                               at /home/mb/.cargo/registry/src/github.com-1ecc6299db9ec823/smelling_salts-0.1.0/src/device.rs:287:47
  27:     0x55e5cd28e59d - std::sys_common::backtrace::__rust_begin_short_backtrace::h48fc034b0cfffb4a
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/sys_common/backtrace.rs:125:18
  28:     0x55e5cd290bbb - std::thread::Builder::spawn_unchecked::{{closure}}::{{closure}}::h52335012d567bae9
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/thread/mod.rs:474:17
  29:     0x55e5cd293d1e - <std::panic::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::hd29b5c94251702d2
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panic.rs:344:9
  30:     0x55e5cd2956db - std::panicking::try::do_call::hba292b0b1d6abbd2
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panicking.rs:379:40
  31:     0x55e5cd295b7d - __rust_try
  32:     0x55e5cd295640 - std::panicking::try::h116fce3b3209b39b
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panicking.rs:343:19
  33:     0x55e5cd29416e - std::panic::catch_unwind::hf01dd7307e48d495
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/panic.rs:431:14
  34:     0x55e5cd2909e9 - std::thread::Builder::spawn_unchecked::{{closure}}::hc2b90c107063f7f8
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/thread/mod.rs:473:30
  35:     0x55e5cd28ebcf - core::ops::function::FnOnce::call_once{{vtable.shim}}::h95810e7249edbcd8
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/core/src/ops/function.rs:227:5
  36:     0x55e5cd2c811a - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h61144a2be4ee36d8
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/alloc/src/boxed.rs:1521:9
  37:     0x55e5cd2c811a - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::hcf5d395fdd120c17
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/alloc/src/boxed.rs:1521:9
  38:     0x55e5cd2c811a - std::sys::unix::thread::Thread::new::thread_start::hb5e40d3d934ebb7a
                               at /rustc/2fd73fabe469357a12c2c974c140f67e7cdd76d0/library/std/src/sys/unix/thread.rs:71:17
  39:     0x7fd08fea1ea7 - start_thread
  40:     0x7fd08fdcbdef - clone
  41:                0x0 - <unknown>
thread panicked while panicking. aborting.
Illegal instruction

I did not try to reproduce this without the stick crate (and therefore without hardware dependency), yet.
Thanks for any hint.

@AgeManning
Copy link
Author

This has since been resolved

@allada
Copy link

allada commented Nov 10, 2021

Any reference to where this was fixed? I also am experiencing this issue and using nightly. The error seems to happen very sporadically, so it is extremely hard to reproduce.

For completeness here's my stack trace:

hread 'tokio-runtime-worker' panicked at 'future still here when dropping', external/raze__futures_util__0_3_17/src/stream/futures_unordered/abort.rs:11:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
thread 'tokio-runtime-worker' panicked at 'panicking twice to abort the program', external/raze__futures_util__0_3_17/src/stream/futures_unordered/abort.rs:6:13
stack backtrace:
   0:     0x561460da6e8c - std::backtrace_rs::backtrace::libunwind::trace::hc6c3491277866fea
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/../../backtrace/src/backtrace/libunwind.rs:93:5
   1:     0x561460da6e8c - std::backtrace_rs::backtrace::trace_unsynchronized::h4524f073368a5b13
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:     0x561460da6e8c - std::sys_common::backtrace::_print_fmt::h0d0cace6159902af
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/sys_common/backtrace.rs:67:5
   3:     0x561460da6e8c - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h3e6af6f05919a7fc
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/sys_common/backtrace.rs:46:22
   4:     0x561460dcca1c - core::fmt::write::h72801a82c94e6ff1
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/core/src/fmt/mod.rs:1149:17
   5:     0x561460da0575 - std::io::Write::write_fmt::ha4f5d34aaccbac84
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/io/mod.rs:1697:15
   6:     0x561460da8840 - std::sys_common::backtrace::_print::heed69f5ce9a8e189
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/sys_common/backtrace.rs:49:5
   7:     0x561460da8840 - std::sys_common::backtrace::print::h5f3918bd80c09252
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/sys_common/backtrace.rs:36:9
   8:     0x561460da8840 - std::panicking::default_hook::{{closure}}::h5af30648530eb3d0
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/panicking.rs:211:50
   9:     0x561460da83eb - std::panicking::default_hook::he88d5fb1ba1b4c19
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/panicking.rs:228:9
  10:     0x561460da8f14 - std::panicking::rust_panic_with_hook::h01febc308b2b313b
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/panicking.rs:606:17
  11:     0x561460d83e45 - std::panicking::begin_panic::{{closure}}::h317df240efbcc5e9
  12:     0x561460d83e14 - std::sys_common::backtrace::__rust_end_short_backtrace::hc2e54fb3afe3ff7c
  13:     0x56146089ef9c - std::panicking::begin_panic::h1188e9de1436a8a5
  14:     0x561460d83d69 - core::ptr::drop_in_place<futures_util::stream::futures_unordered::abort::abort::DoublePanic>::hff3b6284e887739c
  15:     0x561460d83def - futures_util::stream::futures_unordered::abort::abort::h4705e4489201c0fd
  16:     0x561460c6ed57 - alloc::sync::Arc<T>::drop_slow::hfd0e8bd45cba4e24
  17:     0x561460c768d9 - futures_task::arc_wake::ArcWake::wake::hf7f5e295352e1592
  18:     0x561460c9063f - <core::future::from_generator::GenFuture<T> as core::future::future::Future>::poll::h83c6bfdb8fefe900
  19:     0x561460c90c0b - <core::future::from_generator::GenFuture<T> as core::future::future::Future>::poll::he40790bd40ec11fc
  20:     0x561460c88347 - tokio::runtime::task::core::CoreStage<T>::poll::h0088d6f92fc93339
  21:     0x561460c847d4 - tokio::runtime::task::harness::Harness<T,S>::poll::h3ee40180067e75ca
  22:     0x561460d520ff - tokio::runtime::thread_pool::worker::Context::run_task::h92259b81af0d37c0
  23:     0x561460d511e0 - tokio::runtime::thread_pool::worker::Context::run::h94acd4e17715460c
  24:     0x561460d3bc35 - tokio::macros::scoped_tls::ScopedKey<T>::set::h7be99ee0c3b79886
  25:     0x561460d50fcc - tokio::runtime::thread_pool::worker::run::hea50e2ce1155c2a0
  26:     0x561460d55b9f - tokio::loom::std::unsafe_cell::UnsafeCell<T>::with_mut::h226ff042cc86117b
  27:     0x561460d475f6 - tokio::runtime::task::harness::Harness<T,S>::poll::heef31129b17ba7bb
  28:     0x561460d466d2 - tokio::runtime::blocking::pool::Inner::run::hfe3213a9afa83031
  29:     0x561460d54eca - std::sys_common::backtrace::__rust_begin_short_backtrace::h36d13d7b01eb7a70
  30:     0x561460d554c8 - core::ops::function::FnOnce::call_once{{vtable.shim}}::h68d331938f647171
  31:     0x561460dadcb3 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::hd81bd86213781012
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/alloc/src/boxed.rs:1691:9
  32:     0x561460dadcb3 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h7b3e346f5d8f6d6a
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/alloc/src/boxed.rs:1691:9
  33:     0x561460dadcb3 - std::sys::unix::thread::Thread::new::thread_start::ha575792f17151d60
                               at /rustc/ff0e14829e1806ca0d4226595f7fdf3e8658758f/library/std/src/sys/unix/thread.rs:106:17
  34:     0x7f3733f42450 - start_thread
                               at ./nptl/./nptl/pthread_create.c:473:8
  35:     0x7f3733d0dd53 - clone
  36:                0x0 - <unknown>
thread panicked while panicking. aborting.
Illegal instruction (core dumped)

host: linux (ubuntu 20.04)
cpu: x86_x64
nightly: 2021-11-01

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-stream Area: futures::stream
Projects
None yet
Development

No branches or pull requests

5 participants