From f9cd12b3746629f7b661a874bea5c922186c4d99 Mon Sep 17 00:00:00 2001 From: Noah <2+noah@noreply.gitea.bluefla.re> Date: Fri, 13 Nov 2026 10:18:36 -0600 Subject: [PATCH] feat(gui): drop typed-FLASH step; raise report-relay rate limit Issue #41: installing alkane OS and restoring to stock no longer require typing FLASH. The dialog, the board list and the Install/Restore button are the confirmation; the destructive-action warning stays visible. Removes the now-unused confirm inputs from the install and uninstall dialogs. Report relay: raise RATE_PER_IP 5 -> 100 and RATE_GLOBAL 60 -> 300 so bench testing can file more reports without hitting the hourly cap. Applied live on the Gitea host and recorded here. Co-Authored-By: Claude Opus 4.8 Claude-Session: https://claude.ai/code/session_01B1W6qKwKxq3oUPDKWicM6i --- crates/alkane-gui/src/ui.rs | 43 +++++++--------------------------- tools/report-relay/compose.yml | 4 ++-- 2 files changed, 10 insertions(+), 37 deletions(-) diff --git a/crates/alkane-gui/src/ui.rs b/crates/alkane-gui/src/ui.rs index 482d8a92..020c8217 100644 --- a/crates/alkane-gui/src/ui.rs +++ b/crates/alkane-gui/src/ui.rs @@ -906,7 +906,6 @@ pub struct App { install_release_choice: Widget, install_pass_input: Widget, install_unsigned_check: Widget, - install_confirm_input: Widget, install_releases: Vec, install_ips: Vec, install_board: String, @@ -917,7 +916,6 @@ pub struct App { uninstall_dialog: Widget, uninstall_pass_input: Widget, uninstall_firmware_input: Widget, - uninstall_confirm_input: Widget, uninstall_ips: Vec, // Configure-pools dialog (round 14 #7, expanded round 15 #1): 3 pool rows x 4 // fields (address, account, worker, password) = 12 text controls, indexed @@ -1298,7 +1296,6 @@ pub fn build(frame: Widget) -> App { install_release_choice: frame, install_pass_input: frame, install_unsigned_check: frame, - install_confirm_input: frame, install_releases: Vec::new(), install_ips: Vec::new(), install_board: stock_ops::DEFAULT_BOARD.to_string(), @@ -1307,7 +1304,6 @@ pub fn build(frame: Widget) -> App { uninstall_dialog: frame, uninstall_pass_input: frame, uninstall_firmware_input: frame, - uninstall_confirm_input: frame, uninstall_ips: Vec::new(), pools_dialog: frame, pool_fields: Vec::new(), @@ -2775,23 +2771,17 @@ impl App { root.add(unsigned, 0, sf::BORDER_ALL, 12); self.install_unsigned_check = unsigned; + // No typed-FLASH step (issue #41): the dialog, the board list and the + // Install button are the confirmation. The warning stays visible. root.add( Widget::static_text( dlg, - "This reflashes the control board. Type FLASH to confirm:", + "This reflashes the control board. Click Install to start.", ), 0, - sf::BORDER_LEFT | sf::BORDER_RIGHT | sf::BORDER_TOP, + sf::BORDER_ALL, 12, ); - let confirm = Widget::text_ctrl(dlg, false); - root.add( - confirm, - 0, - sf::EXPAND | sf::BORDER_LEFT | sf::BORDER_RIGHT, - 12, - ); - self.install_confirm_input = confirm; let btns = Widget::box_sizer(false); btns.add_stretch(1); @@ -2827,13 +2817,6 @@ impl App { self.install_dialog.close(0); return; } - if !flash_confirmed(&self.install_confirm_input.get_value()) { - // Keep the dialog open; the typed confirmation is the only thing - // missing. A plain status line was easy to miss (issue #38), so this - // also raises the visible error indicator. - self.set_error_indicator("type FLASH in the confirmation box to start the install"); - return; - } let board = self.install_board.clone(); // Source: a local .afw the operator picked takes precedence; otherwise // the selected Gitea release's asset for this board. @@ -2956,23 +2939,17 @@ impl App { root.add(pass, 0, sf::EXPAND | sf::BORDER_LEFT | sf::BORDER_RIGHT, 12); self.uninstall_pass_input = pass; + // No typed-FLASH step (issue #41): the dialog and the Restore button are + // the confirmation. root.add( Widget::static_text( dlg, - "This reflashes the board back to stock (BOOT.bin preserved).\nType FLASH to confirm:", + "This reflashes the board back to stock (BOOT.bin preserved). Click Restore to start.", ), 0, - sf::BORDER_LEFT | sf::BORDER_RIGHT | sf::BORDER_TOP, + sf::BORDER_ALL, 12, ); - let confirm = Widget::text_ctrl(dlg, false); - root.add( - confirm, - 0, - sf::EXPAND | sf::BORDER_LEFT | sf::BORDER_RIGHT, - 12, - ); - self.uninstall_confirm_input = confirm; let btns = Widget::box_sizer(false); btns.add_stretch(1); btns.add( @@ -3001,10 +2978,6 @@ impl App { self.uninstall_dialog.close(0); return; } - if !flash_confirmed(&self.uninstall_confirm_input.get_value()) { - wx_rs::set_status_text("type FLASH to confirm the restore"); - return; - } let firmware = self.uninstall_firmware_input.get_value(); let firmware = firmware.trim(); if firmware.is_empty() { diff --git a/tools/report-relay/compose.yml b/tools/report-relay/compose.yml index ef542543..ed8b0965 100644 --- a/tools/report-relay/compose.yml +++ b/tools/report-relay/compose.yml @@ -15,8 +15,8 @@ services: GITEA_URL: http://gitea:3000 GITEA_REPO: blueflare/alkane-toolkit GITEA_TOKEN_FILE: /run/secrets/gitea_token - RATE_PER_IP: "5" - RATE_GLOBAL: "60" + RATE_PER_IP: "100" + RATE_GLOBAL: "300" volumes: - ./secrets/gitea_token:/run/secrets/gitea_token:ro networks: [proxy]