Keep the current SSH session open if removal reports post-deinstall and exit status 127. Record the package version, target architecture and script name from the error. Check new logins, the package database and possible leftover files separately.
Check the login shell before removing fish
Run these read-only checks on the router. The account listing shows only account names and login shells. If the administration account uses fish, change it to an installed executable shell using the system's supported account management method. Open a second SSH connection and confirm login before closing the first session or removing the package.
awk -F: '{print $1,$7}' /etc/passwd
test -x /bin/ash && echo ash-available
apk list --installed fish
apk del --simulate fish
Check the package record and a fresh session after removal
On our isolated 25.12.6 x86/64 guest, root used /bin/ash and the simulated removal of fish 4.7.1-r1 listed two additional libraries. After actual removal the installed-package query returned no fish entry. A 4.1.2-r2 cleanup script failed on 25.12.3 ramips/mt7621. These different environments do not establish a fix across architectures. Stop at the preview if it lists packages you still need.
apk list --installed fish
command -v fish || echo no-fish-command
test -x /bin/ash && echo ash-available

If the command remains, inspect its path and package owner. If the package record is gone and a fresh login works, save the log and check leftover paths against the packaging script for that version. Avoid deleting shared directories recursively by name. If login depends on fish, keep management access open, restore a compatible version from the same feed and test a second connection.
Comments