Multiple examples not working in 0.13 and master-branch on web
Author: mahlquistjCreated Jun 3, 2025Updated Sep 27, 2026
Labelsbug
Is your issue REALLY a bug?
- My issue is indeed a bug!
- I am not crazy! I will not fill out this form just to ask a question or request a feature. Pinky promise.
Is there an existing issue for this?
- I have searched the existing issues.
Is this issue related to iced?
- My hardware is compatible and my graphics drivers are up-to-date.
What happened?
Nothing is shown and/or the program panics for multiple examples when running in web. Everything works as expected, when running natively.
When running the download_progress example, nothing shows up, but no errors seem to occur (On both 0.13 and master).
When running the tour example nothing shows up on the 0.13 branch and fails with the error included below
On the master branch, it works, but no image shows up in the Image section of the tour.
I'm using trunk serve to run the examples.
What is the expected behavior?
GUI should show.
Version
master
Operating System
Linux
Do you have any log output?
/home/maj/iced/tiny_skia/src/window/compositor.rs:68:10:
Create softbuffer surface for window: PlatformError(Some("A canvas context other than `CanvasRenderingContext2d` was already created"), None)
Stack:
Error
at imports.wbg.__wbg_new_8a6f238a6ece86ea (http://localhost:8080/tour-2300059b7b09060f.js:1637:21)
at tour-765cd0ae65663b94.wasm.__wbg_new_8a6f238a6ece86ea externref shim (http://localhost:8080/tour-2300059b7b09060f_bg.wasm:wasm-function[73245]:0x19bbc04)
at tour-765cd0ae65663b94.wasm.console_error_panic_hook::Error::new::h738824dee35cf346 (http://localhost:8080/tour-2300059b7b09060f_bg.wasm:wasm-function[47722]:0x1841c41)
at tour-765cd0ae65663b94.wasm.console_error_panic_hook::hook_impl::h50c76f0933731058 (http://localhost:8080/tour-2300059b7b09060f_bg.wasm:wasm-function[12829]:0x11f6b74)
at tour-765cd0ae65663b94.wasm.console_error_panic_hook::hook::h438236fc27abc666 (http://localhost:8080/tour-2300059b7b09060f_bg.wasm:wasm-function[63617]:0x19520ea)
at tour-765cd0ae65663b94.wasm.core::ops::function::Fn::call::h1669d9129d12a2c4 (http://localhost:8080/tour-2300059b7b09060f_bg.wasm:wasm-function[56143]:0x18e367b)
at tour-765cd0ae65663b94.wasm.std::panicking::rust_panic_with_hook::h1f8226e239ffaa71 (http://localhost:8080/tour-2300059b7b09060f_bg.wasm:wasm-function[24335]:0x15239a1)
at tour-765cd0ae65663b94.wasm.std::panicking::begin_panic_handler::{{closure}}::hc8d13715338b2080 (http://localhost:8080/tour-2300059b7b09060f_bg.wasm:wasm-function[31803]:0x16773ad)
at tour-765cd0ae65663b94.wasm.std::sys::backtrace::__rust_end_short_backtrace::hab1143a2823b7bb3 (http://localhost:8080/tour-2300059b7b09060f_bg.wasm:wasm-function[74214]:0x19bf004)
at tour-765cd0ae65663b94.wasm.__rustc[95feac21a9532783]::rust_begin_unwind (http://localhost:8080/tour-2300059b7b09060f_bg.wasm:wasm-function[69874]:0x19a0608)
imports.wbg.__wbg_error_7534b8e9a36f1ab4 @ tour-2300059b7b09060f.js:1026
$console_error_panic_hook::error::h439ecbb9df21d18a @ tour-2300059b7b09060f_bg.wasm:0x16b5cc0
$console_error_panic_hook::hook_impl::h50c76f0933731058 @ tour-2300059b7b09060f_bg.wasm:0x11f6c65
$console_error_panic_hook::hook::h438236fc27abc666 @ tour-2300059b7b09060f_bg.wasm:0x19520ea
$core::ops::function::Fn::call::h1669d9129d12a2c4 @ tour-2300059b7b09060f_bg.wasm:0x18e367b
$std::panicking::rust_panic_with_hook::h1f8226e239ffaa71 @ tour-2300059b7b09060f_bg.wasm:0x15239a1
$std::panicking::begin_panic_handler::{{closure}}::hc8d13715338b2080 @ tour-2300059b7b09060f_bg.wasm:0x16773ad
$std::sys::backtrace::__rust_end_short_backtrace::hab1143a2823b7bb3 @ tour-2300059b7b09060f_bg.wasm:0x19bf004
$__rustc[95feac21a9532783]::rust_begin_unwind @ tour-2300059b7b09060f_bg.wasm:0x19a0608
$core::panicking::panic_fmt::hb6c28595a1feee80 @ tour-2300059b7b09060f_bg.wasm:0x19a0635
$core::result::unwrap_failed::h0af004c27326640f @ tour-2300059b7b09060f_bg.wasm:0x17252b5
$core::result::Result<T,E>::expect::hebe4052dde33735f @ tour-2300059b7b09060f_bg.wasm:0x12e29d5
$<iced_tiny_skia::window::compositor::Compositor as iced_graphics::compositor::Compositor>::create_surface::hd6978ae280deab4d @ tour-2300059b7b09060f_bg.wasm:0xd1e99b
$<iced_renderer::fallback::Compositor<A,B> as iced_graphics::compositor::Compositor>::create_surface::he5bfcc3410e0455e @ tour-2300059b7b09060f_bg.wasm:0xf8b9a9
$iced_winit::program::window_manager::WindowManager<P,C>::insert::h9c5891bf7ff18c0f @ tour-2300059b7b09060f_bg.wasm:0xe56148
$iced_winit::program::run_instance::{{closure}}::h397ff6e8b56f84f9 @ tour-2300059b7b09060f_bg.wasm:0x233534
$iced_winit::program::run::Runner<Message,F,C>::process_event::hb3d044d4a0a0181f @ tour-2300059b7b09060f_bg.wasm:0x61e55c
$iced_winit::program::run::Runner<Message,F,C>::process_event::hb3d044d4a0a0181f @ tour-2300059b7b09060f_bg.wasm:0x61f96d
$<iced_winit::program::run::Runner<Message,F,C> as winit::application::ApplicationHandler<iced_runtime::Action<Message>>>::user_event::h92cad44f086f4734 @ tour-2300059b7b09060f_bg.wasm:0x161e40e
$<winit::event_loop::EventLoop<T> as winit::platform::web::EventLoopExtWebSys>::spawn_app::{{closure}}::h45bae18a5e485128 @ tour-2300059b7b09060f_bg.wasm:0xd4028c
$winit::platform_impl::web::event_loop::EventLoop<T>::spawn::{{closure}}::h7e9b6e7d3e925336 @ tour-2300059b7b09060f_bg.wasm:0xf32d1c
$<alloc::boxed::Box<F,A> as core::ops::function::FnMut<Args>>::call_mut::h98a2dbe5767b02fc @ tour-2300059b7b09060f_bg.wasm:0x16f593b
$winit::platform_impl::web::event_loop::runner::Runner::handle_single_event::ha91f4045a75903f3 @ tour-2300059b7b09060f_bg.wasm:0xe96c55
$winit::platform_impl::web::event_loop::runner::Shared::handle_event::h700ec3a1c8ab4cb6 @ tour-2300059b7b09060f_bg.wasm:0x97529f
$winit::platform_impl::web::event_loop::runner::Shared::handle_event::h700ec3a1c8ab4cb6 @ tour-2300059b7b09060f_bg.wasm:0x97589c
$winit::platform_impl::web::event_loop::runner::Shared::run_until_cleared::hc85015134d0db8a0 @ tour-2300059b7b09060f_bg.wasm:0xd38111
$winit::platform_impl::web::event_loop::runner::Shared::poll::h8bb08af73476720e @ tour-2300059b7b09060f_bg.wasm:0x12c76e5
$winit::platform_impl::web::event_loop::runner::Shared::apply_control_flow::{{closure}}::h2f9ec35175809e73 @ tour-2300059b7b09060f_bg.wasm:0x19564ac
$<dyn core::ops::function::FnMut<()>+Output = R as wasm_bindgen::closure::WasmClosure>::describe::invoke::h4fee4fb03a9087da @ tour-2300059b7b09060f_bg.wasm:0x166da83
__wbg_adapter_53 @ tour-2300059b7b09060f.js:285
real @ tour-2300059b7b09060f.js:177
postTask
imports.wbg.__wbg_postTask_62a4b94ee65c66c5 @ tour-2300059b7b09060f.js:1774
$__wbg_postTask_62a4b94ee65c66c5 externref shim @ tour-2300059b7b09060f_bg.wasm:0x19b7b74
$winit::platform_impl::web::web_sys::schedule::Scheduler::post_task_with_options::h9522b5e2c9ae1921 @ tour-2300059b7b09060f_bg.wasm:0x15aa4c7
$winit::platform_impl::web::web_sys::schedule::Schedule::new_scheduler::{{closure}}::h19a25b9dcd0b88f1 @ tour-2300059b7b09060f_bg.wasm:0x160ebaa
$std::thread::local::LocalKey<T>::try_with::h19f209c66dfd7d39 @ tour-2300059b7b09060f_bg.wasm:0x1388132
$std::thread::local::LocalKey<T>::with::hf69d7c114f40a4b0 @ tour-2300059b7b09060f_bg.wasm:0x17d5512
$winit::platform_impl::web::web_sys::schedule::Schedule::new_scheduler::h070069c1027c5fdd @ tour-2300059b7b09060f_bg.wasm:0xd9f215
$winit::platform_impl::web::web_sys::schedule::Schedule::new::hbf04dc7ce6a29d2b @ tour-2300059b7b09060f_bg.wasm:0x130fa37
$winit::platform_impl::web::event_loop::runner::Shared::apply_control_flow::h88e4d5641faa8890 @ tour-2300059b7b09060f_bg.wasm:0xac91c9
$winit::platform_impl::web::event_loop::runner::Shared::run_until_cleared::h59ff726ed0291760 @ tour-2300059b7b09060f_bg.wasm:0xd37f8e
$winit::platform_impl::web::event_loop::runner::Shared::init::h0afd11a67836123e @ tour-2300059b7b09060f_bg.wasm:0x10b45de
$winit::platform_impl::web::event_loop::runner::Shared::set_listener::h83c62fb0102fc370 @ tour-2300059b7b09060f_bg.wasm:0x5f1cf9
$winit::platform_impl::web::event_loop::window_target::ActiveEventLoop::run::h38f1ec6834fbcbb1 @ tour-2300059b7b09060f_bg.wasm:0x181bc15
$winit::platform_impl::web::event_loop::EventLoop<T>::spawn::h9c29b3036d4e5b43 @ tour-2300059b7b09060f_bg.wasm:0x136125d
$<winit::event_loop::EventLoop<T> as winit::platform::web::EventLoopExtWebSys>::spawn_app::h199f7e1b39dd0d92 @ tour-2300059b7b09060f_bg.wasm:0x15a9d5d
$iced_winit::program::run::h9864df1dfdd2bc01 @ tour-2300059b7b09060f_bg.wasm:0x4f2324
$iced::program::Program::run_with::h67da2179a68b89c6 @ tour-2300059b7b09060f_bg.wasm:0xbbf1f3
$iced::program::Program::run::h39572307128191fa @ tour-2300059b7b09060f_bg.wasm:0x197d7d4
$iced::application::Application<P>::run::h4e55ff3a9ee6a205 @ tour-2300059b7b09060f_bg.wasm:0x1187abd
$tour::main::h8930d06e9fb86ece @ tour-2300059b7b09060f_bg.wasm:0x158c8e1
$core::ops::function::FnOnce::call_once::h20079d20b9548da2 @ tour-2300059b7b09060f_bg.wasm:0x193efd9
$std::sys::backtrace::__rust_begin_short_backtrace::h604a155daefe64da @ tour-2300059b7b09060f_bg.wasm:0x193f855
$std::rt::lang_start::{{closure}}::h8b2e521f262cfd99 @ tour-2300059b7b09060f_bg.wasm:0x17fd3c6
$std::rt::lang_start_internal::h51312c7ab5cd6cef @ tour-2300059b7b09060f_bg.wasm:0x166cd3b
$std::rt::lang_start::hab9af8cafb416b81 @ tour-2300059b7b09060f_bg.wasm:0x177ea5b
$main @ tour-2300059b7b09060f_bg.wasm:0x19b7db8
$func73629 @ tour-2300059b7b09060f_bg.wasm:0x19bd3ff
$__wbindgen_start @ tour-2300059b7b09060f_bg.wasm:0x19bf5ee
__wbg_finalize_init @ tour-2300059b7b09060f.js:2529
__wbg_init @ tour-2300059b7b09060f.js:2583
await in __wbg_init
(anonymous) @ (index):13Source: iced-rs/iced