You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
sqlx::query("SELECT ... from ... where id = ?",).bind(id).fetch_optional(&mut*conn).await?
.map(|row| .......)
error backtrace
thread 'test_schedule_job' panicked at 'assertion failed: `(left == right)`
left: `8174`,
right: `8192`', /Users/liangyongrui/.cargo/git/checkouts/sqlx-f05f33ba4f5c3036/5c532a8/sqlx-core/src/io/buf_stream.rs:77:17
stack backtrace:
0: <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt
1: core::fmt::write
2: std::io::Write::write_fmt
3: std::panicking::default_hook::{{closure}}
4: std::panicking::default_hook
5: std::panicking::rust_panic_with_hook
6: std::panicking::continue_panic_fmt
7: std::panicking::begin_panic_fmt
8: sqlx_core::io::buf_stream::BufStream<S>::peek::{{closure}}
9: <std::future::GenFuture<T> as core::future::future::Future>::poll::{{closure}}
10: std::future::set_task_context
11: <std::future::GenFuture<T> as core::future::future::Future>::poll
12: std::future::poll_with_tls_context::{{closure}}
13: std::future::get_task_context
14: std::future::poll_with_tls_context
15: sqlx_core::mysql::connection::MySqlConnection::try_receive::{{closure}}
16: <std::future::GenFuture<T> as core::future::future::Future>::poll::{{closure}}
17: std::future::set_task_context
18: <std::future::GenFuture<T> as core::future::future::Future>::poll
19: std::future::poll_with_tls_context::{{closure}}
20: std::future::get_task_context
21: std::future::poll_with_tls_context
22: sqlx_core::mysql::connection::MySqlConnection::receive::{{closure}}
23: <std::future::GenFuture<T> as core::future::future::Future>::poll::{{closure}}
24: std::future::set_task_context
25: <std::future::GenFuture<T> as core::future::future::Future>::poll
26: std::future::poll_with_tls_context::{{closure}}
27: std::future::get_task_context
28: std::future::poll_with_tls_context
29: sqlx_core::mysql::executor::<impl sqlx_core::mysql::connection::MySqlConnection>::prepare_with_cache::{{closure}}
30: <std::future::GenFuture<T> as core::future::future::Future>::poll::{{closure}}
31: std::future::set_task_context
32: <std::future::GenFuture<T> as core::future::future::Future>::poll
33: std::future::poll_with_tls_context::{{closure}}
34: std::future::get_task_context
35: std::future::poll_with_tls_context
36: sqlx_core::mysql::executor::<impl sqlx_core::mysql::connection::MySqlConnection>::fetch::{{closure}}
37: <std::future::GenFuture<T> as core::future::future::Future>::poll::{{closure}}
38: std::future::set_task_context
39: <std::future::GenFuture<T> as core::future::future::Future>::poll
40: <async_stream::async_stream::AsyncStream<T,U> as futures_core::stream::Stream>::poll_next
41: <core::pin::Pin<P> as futures_core::stream::Stream>::poll_next
42: <S as futures_core::stream::TryStream>::try_poll_next
43: futures_util::stream::try_stream::TryStreamExt::try_poll_next_unpin
44: <futures_util::stream::try_stream::try_next::TryNext<St> as core::future::future::Future>::poll
45: std::future::poll_with_tls_context::{{closure}}
46: std::future::get_task_context
47: std::future::poll_with_tls_context
48: sqlx_core::executor::Executor::fetch_optional::{{closure}}
49: <std::future::GenFuture<T> as core::future::future::Future>::poll::{{closure}}
50: std::future::set_task_context
51: <std::future::GenFuture<T> as core::future::future::Future>::poll
52: <core::pin::Pin<P> as core::future::future::Future>::poll
53: std::future::poll_with_tls_context::{{closure}}
54: std::future::get_task_context
55: std::future::poll_with_tls_context
56: sqlx_core::query::Query<DB,P>::fetch_optional::{{closure}}
57: <std::future::GenFuture<T> as core::future::future::Future>::poll::{{closure}}
58: std::future::set_task_context
59: <std::future::GenFuture<T> as core::future::future::Future>::poll
60: std::future::poll_with_tls_context::{{closure}}
61: std::future::get_task_context
62: std::future::poll_with_tls_context
...
buf_stream.rs 77:17
// If we are out of space to write to in the read buffer,// we reset the indexesifself.rbuf.len() < (self.rbuf_windex + cnt){// TODO: This assumes that all data is consumed when we need to re-allocatedebug_assert_eq!(self.rbuf_rindex,self.rbuf_windex);self.rbuf_rindex = 0;self.rbuf_windex = 0;}
The text was updated successfully, but these errors were encountered:
Thanks for reporting. This looks like a simple oversight as master was clearly unfinished there. I finished the implementation there and added a test to make sure it works.
dependencies
code
error backtrace
buf_stream.rs 77:17
The text was updated successfully, but these errors were encountered: