-
Notifications
You must be signed in to change notification settings - Fork 293
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
🐛 BUG: Any delay will cause the server to error #595
Comments
Update: Since updating to wrangler 3.36.0, there is now an error on the page, linking to this file and location:
I believe this is the file on GitHub. The problem hasn't resolved yet. |
I'm going to transfer this to the |
I'm not sure exactly how the runtime detects that futures arent making progress, but I suspect the blocking sleep here is the issue. Can you use an async sleep such as |
We have a use std::time::Duration;
use worker::Delay;
let duration = Duration::from_millis(1000);
// Waits a second
Delay::from(duration).await; |
Which Cloudflare product(s) does this pertain to?
Workers Runtime, Wrangler core
What version(s) of the tool(s) are you using?
3.34.2 [Wrangler], 0.0.21 [workers-rs], 1.78.0-nightly [Rust]
What version of Node are you using?
21.7.1
What operating system and version are you using?
Linux (Fedora) (arm64)
Describe the Bug
Observed behavior
If a minimal delay (or some work) is introduced, the server throws an error.
The log is the following:
Expected behavior
I would expect the work to finish and to respond to the request.
Steps to reproduce
wrangler.toml
I also tried using wrangler beta, but to avail.
Nothing
Please provide a link to a minimal reproduction
No response
Please provide any relevant error logs
This is a log of starting the local server, opening the page, and then closing the server:
The text was updated successfully, but these errors were encountered: