libnyanpasu/clash-nyanpasu · error
failed to uninstall service, exit code
Error message
failed to uninstall service, exit code: {} What it means
uninstall_service ran the elevated service uninstaller (RunasCommand on Windows, sudo on macOS) and the child process exited non-zero, so the nyanpasu service was not removed. This is a check on the spawned uninstaller's ExitStatus: failure typically means the elevation prompt was denied or the uninstaller could not remove the service registration.
Solutions
- Retry the uninstall and accept the elevation prompt.
- Run the service binary manually with the `uninstall` argument as administrator to see the underlying error.
- Check whether the service is still running; stop it before uninstalling.
- Manually delete the OS service registration (e.g. `sc delete` on Windows / launchd plist removal on macOS) if the uninstaller keeps failing.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at backend/tauri/src/core/service/control.rs:166 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of libnyanpasu/clash-nyanpasu@f7dbce2997 (2026-09-08).
Data as JSON: /api/errors/b230fd6cc8ac4f36.
Report an issue: GitHub.
Appendix: source
Thrown at backend/tauri/src/core/service/control.rs:166
})
.await??;
if !child.success() {
anyhow::bail!(
"failed to uninstall service, exit code: {}",
child.code().unwrap()
);
}
Ok(())
}View on GitHub (pinned to f7dbce2997)