tauri-apps/tauri · critical
not implemented
Error message
not implemented
What it means
In Tauri's on_window_event handler, the DragDrop match falls through to an `unimplemented!()` catch-all for DragDropEvent variants other than Enter/Drop/Leave (e.g. DraggedOver/Dragged with payload variants not handled here). This is a deliberate internal placeholder: reaching it means a runtime drag-drop event shape the manager code was never written to handle. It panics (process abort of the event loop task) rather than returning a recoverable Result.
Solutions
- Update Tauri to a version where all DragDropEvent variants are handled in on_window_event
- File/check an upstream issue: this panic indicates a missing match arm in crates/tauri/src/manager/window.rs
- As a workaround, avoid enabling drag-drop on windows until patched, or filter the event before it reaches the manager
- If maintaining a fork, add explicit arms for the missing DragDropEvent variants (e.g. Dragged/DraggedOver) mirroring the Drop arm's emit logic
Example fix
// before
_ => unimplemented!(),
// after
DragDropEvent::DraggedOver { position } => {
window.emit_to_window(DRAG_OVER_EVENT, &position)?
}
_ => Ok(()), // or log-and-ignore unknown variants Defensive patterns
Strategy: fallback
Validate before calling
if let WindowEvent::DragDrop(e) = event {
match e {
DragDropEvent::Enter { .. } | DragDropEvent::Drop { .. } | DragDropEvent::Leave => {},
other => eprintln!("unhandled drag-drop variant: {other:?}"),
}
} Try / catch
// unimplemented!() panics; it cannot be caught in Rust. Register on_window_event and ensure only supported variants flow, or wrap the app run in catch_unwind as a last resort: std::panic::catch_unwind(|| tauri::Builder::default().run(ctx));
Prevention
- Keep Tauri updated so newly added DragDropEvent variants are handled upstream
- Avoid custom runtime/event-loop forks that emit raw drag variants
- Watch upstream issues for drag-drop panics before enabling dragDropEnabled
When it happens
Trigger: A WindowEvent::DragDrop variant other than the explicitly matched ones (Enter, Drop, Leave) reaches on_window_event via attach_window — i.e. the runtime emits a drag-drop sub-event (such as a drag-over/move variant) the manager has no arm for.
Common situations: Users dragging content over a Tauri window continuously (drag-over events) on platforms where the runtime forwards those variants; using a runtime/version combination where new DragDropEvent variants were added but manager/window.rs was not updated; custom event-loop integrations forwarding raw drag events.
Related errors
- not implemented
- cannot use both `resources` and `resources_map`
- failed to canonicalize global API script path
- failed to get exe directory
- failed to parse plugin global API script paths
AI-assisted analysis of tauri-apps/tauri@460ec35447 (2026-09-18).
Data as JSON: /api/errors/943153629d75eac6.
Report an issue: GitHub.
Appendix: source
Thrown at crates/tauri/src/manager/window.rs:269
EmitPayload::Serialize(&payload),
)?
} else {
window.emit_to_window(DRAG_DROP_EVENT, &payload)?
}
}
DragDropEvent::Leave => {
if window.is_webview_window() {
// use underlying manager, otherwise have to recheck EventName
window.manager().emit_to(
EventTarget::labeled(window.label()),
DRAG_LEAVE_EVENT,
EmitPayload::Serialize(&()),
)?
} else {
window.emit_to_window(DRAG_LEAVE_EVENT, &())?
}
}
_ => unimplemented!(),
},
WindowEvent::ThemeChanged(theme) => window.emit_to_window(WINDOW_THEME_CHANGED, &theme)?,
#[cfg(mobile)]
WindowEvent::Suspended => window.emit_to_window(WINDOW_SUSPENDED_EVENT, &())?,
#[cfg(mobile)]
WindowEvent::Resumed => window.emit_to_window(WINDOW_RESUMED_EVENT, &())?,
}
Ok(())
}
#[derive(Clone, Serialize)]
#[serde(rename_all = "camelCase")]
struct ScaleFactorChanged {
scale_factor: f64,
size: PhysicalSize<u32>,
}
View on GitHub (pinned to 460ec35447)