Unhelpful error message when attempt to retrieve Timer handle in same line as Timer created with ::default()
or ::new()
#727
Labels
E-needs-mcve
Call for participation: This issue needs a Minimal Complete and Verifiable Example
Version
Platform
Darwin Kernel Version 16.7.0: Thu Jun 21 20:07:39 PDT 2018; root:xnu-3789.73.14~1/RELEASE_X86_64 x86_64
Subcrates
Description
When creating a new Timer I experience unhelpful errors if I attempt to both create the
Timer
and get it's handle in one line. The documentation for tokio_timer::timer::Timer::new() does suggest that the two steps must be separate by stating that "once the timer has been created, a handle can be obtained usinghandle
"; however, it was not easy to track down with the given information especially given theIllegal Operation: 4
error I was returning when first debugging the issue.Code
Errors encountered
thread panicked while processing panic. aborting.
Illegal Operation: 4
or (more helpful)
tokio timer error: timer is shutdown
More complete code example
Also found here: https://github.com/graphprotocol/graph-node/blob/ford/tokio-blockon/node/src/main.rs#L59
The text was updated successfully, but these errors were encountered: