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
Trying to use env_logger's but I cannot make it work.
env_logger::init() doesn't enable the work because RUST_LOG environment variable is not set ( I couldn't make it work, that's presumably because wasm doesn't have access to env?).
✘ [ERROR] service core:user:PROJECT: Uncaught RuntimeError: unreachable
at [object Object] in $func1519
at [object Object] in $func993
at [object Object] in $func1069
at [object Object] in $func1489
at [object Object] in $func1272
at [object Object] in $func1271
at [object Object] in $func1253
at [object Object] in $func259
at [object Object] in $func158
at [object Object] in $func204
✘ [ERROR] The Workers runtime failed to start. There is likely additional logging output above.
Steps To Reproduce
Use env_logger in worker code, e.g.:
#[event(start)]
fn start() {
console_log!("Worker started successfully!");
// env_logger::init(); // Doesn't work
env_logger::builder().filter_level(log::LevelFilter::Debug).init(); // Crash
info!("Worker started successfully!");
}
The text was updated successfully, but these errors were encountered:
Is there an existing issue for this?
What version of
workers-rs
are you using?0.5.0
What version of
wrangler
are you using?3.103.2
Describe the bug
Trying to use
env_logger
's but I cannot make it work.env_logger::init()
doesn't enable the work becauseRUST_LOG
environment variable is not set ( I couldn't make it work, that's presumably because wasm doesn't have access to env?).After that attempt I tried to use
but that crashes the worker:
Steps To Reproduce
Use
env_logger
in worker code, e.g.:The text was updated successfully, but these errors were encountered: