tauri-apps/tauri · error
not implemented
Error message
not implemented
What it means
tao_activation_policy maps tauri's ActivationPolicy enum onto tao's on macOS. The match only covers Regular, Accessory and Prohibited; any other variant (e.g. macOS-only additions not yet mapped) reaches unimplemented!. SetActivationPolicy and handle_user_message funnel through this function on macOS.
Solutions
- Only use ActivationPolicy::Regular, Accessory or Prohibited
- Upgrade tauri-runtime-wry/tao to versions where the missing variant is mapped
- Avoid setting the policy at runtime if you only need a default policy
Example fix
// before app.set_activation_policy(ActivationPolicy::SelectControls); // after app.set_activation_policy(ActivationPolicy::Accessory);
Defensive patterns
Strategy: validation
Validate before calling
match policy {
ActivationPolicy::Regular | ActivationPolicy::Accessory | ActivationPolicy::Prohibited => app.set_activation_policy(policy),
_ => eprintln!("unsupported activation policy on macOS backend"),
} Type guard
fn is_supported_policy(p: &ActivationPolicy) -> bool {
matches!(p, ActivationPolicy::Regular | ActivationPolicy::Accessory | ActivationPolicy::Prohibited)
} Prevention
- Restrict activation policies to the three documented variants
- Keep tao versions aligned with tauri-runtime-wry
- Test macOS-specific code paths on macOS in CI
When it happens
Trigger: Calling app.set_activation_policy(ActivationPolicy::...) with a variant not covered by the mapping, or sending the corresponding SetActivationPolicy message through the event loop on macOS.
Common situations: Using a newer ActivationPolicy variant added upstream (e.g. ComboBox/SelectControls from AppKit) that the runtime mapping has not been updated for; version drift between tauri and tao/tao-activation-policy definitions.
Related errors
- not implemented
- not implemented
- not implemented
- Cargo manifest must have the `package.version` field
- Cargo project does not have a version
AI-assisted analysis of tauri-apps/tauri@460ec35447 (2026-09-18).
Data as JSON: /api/errors/5bf09bf1eaafd52d.
Report an issue: GitHub.
Appendix: source
Thrown at crates/tauri-runtime-wry/src/lib.rs:617
}
}
}
pub fn map_theme(theme: &TaoTheme) -> Theme {
match theme {
TaoTheme::Light => Theme::Light,
TaoTheme::Dark => Theme::Dark,
_ => Theme::Light,
}
}
#[cfg(target_os = "macos")]
fn tao_activation_policy(activation_policy: ActivationPolicy) -> TaoActivationPolicy {
match activation_policy {
ActivationPolicy::Regular => TaoActivationPolicy::Regular,
ActivationPolicy::Accessory => TaoActivationPolicy::Accessory,
ActivationPolicy::Prohibited => TaoActivationPolicy::Prohibited,
_ => unimplemented!(),
}
}
pub struct MonitorHandleWrapper(pub MonitorHandle);
impl From<MonitorHandleWrapper> for Monitor {
fn from(monitor: MonitorHandleWrapper) -> Monitor {
Self {
name: monitor.0.name(),
position: monitor.0.position(),
size: monitor.0.size(),
work_area: monitor.0.work_area(),
scale_factor: monitor.0.scale_factor(),
}
}
}
#[cfg(desktop)]View on GitHub (pinned to 460ec35447)