fix(openwrt): detect opkg silent failure and show disk space error
BusyBox opkg exits 0 even when 'Cannot install' due to insufficient space, causing the fallback to silently report success. Now captures stderr and checks for the failure string explicitly. Adds user-visible error for the common case where the router flash is too small for the TollGate package (~19 MB needed vs ~9 MB available on typical budget routers). Adds error prefixes to the RPC sanitizer allowlist so the message reaches the UI instead of showing 'Check server logs'. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -66,6 +66,9 @@ pub(super) fn sanitize_error_message(msg: &str) -> String {
|
||||
"Bitcoin address",
|
||||
"No router",
|
||||
"No OpenWrt",
|
||||
"No space left",
|
||||
"TollGate installation failed",
|
||||
"No pre-built TollGate",
|
||||
];
|
||||
for prefix in &user_facing_prefixes {
|
||||
if msg.starts_with(prefix) {
|
||||
|
||||
Reference in New Issue
Block a user