Repository navigation
fix: typed 404 classification and package-manager guidance for self-update - #33
Merged
Merged
Conversation
…pdate - GitHub not-found detection matched the substring '404' against stringified errors at four call sites: any response body that merely contained '404' classified a live repo as manifest-less, silently dropping it from the catalog and then rewriting the offline cache without it. cached_get now carries a typed HttpStatus in the anyhow chain and callers classify via is_not_found(), which only matches a real HTTP 404. - AUR/pacman installs (exe under /usr or /opt) were offered the full self-update flow, which downloads megabytes and then always dies with EACCES on the backup rename of the running exe. The install location is detected once at boot; the Settings button is replaced with 'update via pacman' guidance, the availability toast says the same, and DownloadLauncherUpdate refuses as defense in depth.
MotherSphere
force-pushed
the
fix/packaged-install-and-typed-404
branch
from
July 20, 2026 16:24
9ab979d to
f98e54f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Contexte (audit 2026-07-20, vague B - lot 3, dernier)
contains("404")sur des erreurs stringifiées à 4 endroits : un body contenant « 404 » par hasard classait un repo vivant comme sans-manifest, le faisait disparaître du catalogue et réécrivait le cache offline sans lui.cached_getporte maintenant unHttpStatustypé dans la chaîne anyhow, et les appelants classifient viais_not_found()(test unitaire inclus : un body « 404 » sur un statut 500 n'est plus un not-found)./usr/bin/colony) se voyait proposer le flux self-update complet, qui télécharge des Mo puis meurt en EACCES sur le rename de l'exe. Détection au boot (/usrou/opt) : le bouton Settings devient un hint « mets à jour via pacman -Syu », le toast de disponibilité dit pareil, etDownloadLauncherUpdaterefuse en défense en profondeur. Clés i18n FR+EN (test de parité vert).Validation
Build + clippy 0 warning, 91 tests verts (nouveau test du downcast 404).