From a02957034df4f941e0434d2c2e532d136eb40811 Mon Sep 17 00:00:00 2001 From: Julian Cuni Date: Tue, 7 Jul 2026 09:54:59 +0200 Subject: [PATCH] fix(web): setup allows adding a printer with no controller configured MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Second half of the printer/relay decoupling: the category section's add-button gate ("add a controller first — a printer points at one of its relays") blocked every non-access category while zero controllers existed — hit on the lab bench (USB printer test, no relays on hand). Printers don't bind (role + failoverRank route jobs), so the gate now exempts them like the form's requirement already does. Claude-Session: https://claude.ai/code/session_01Xcm6ikLgGoCxxHrxtjkk5V --- apps/web/src/SetupWizard.tsx | 6 ++++-- wiki/log.md | 8 ++++++++ 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/apps/web/src/SetupWizard.tsx b/apps/web/src/SetupWizard.tsx index 199678c..7e7e116 100644 --- a/apps/web/src/SetupWizard.tsx +++ b/apps/web/src/SetupWizard.tsx @@ -257,8 +257,10 @@ function CategorySection({ const [formFor, setFormFor] = useState(null); const [warnings, setWarnings] = useState([]); - // Binding categories need a controller to point at first. - const isBound = category !== "access"; + // Binding categories need a controller to point at first. Printers do NOT bind + // (role + failoverRank route print jobs — see printer-routing.ts), so they are + // addable on a controller-less box (e.g. the lab bench testing a USB printer). + const isBound = category !== "access" && category !== "printer"; const blockedNoController = isBound && controllers.length === 0; const editing = formFor && formFor !== "new" ? formFor : undefined; diff --git a/wiki/log.md b/wiki/log.md index f3b5233..557771b 100644 --- a/wiki/log.md +++ b/wiki/log.md @@ -2477,3 +2477,11 @@ June park-buzi install defaulted under $HOME). [[appliance-provisioning]] §7a n root_directory after every install + the sed one-liner fix; also notes `sudo systemctl restart periphery` → "unit not found" (user unit) and that the single-use onboarding key survives a pre-connect crash. + +## [2026-07-07] update | Setup: printers addable with NO controller configured + +Lab bench (USB printer test, no relays on hand) hit a SECOND printer/relay coupling the +2026-07-06 fix missed: the category section's add-button gate ("Shto fillimisht një kontroller…") +blocks every non-access category while zero controllers exist. Printers are now exempt there too +— the binding fix removed the requirement inside the form; this removes the gate in front of it. +A controller-less box can configure + test a printer.