Skip to content

Show Failed instead of Done when an install fails - #19486

Open
ThePrimeagen wants to merge 1 commit into
omacom:quattrofrom
ThePrimeagen:fix/2ed81d03-da7c-4892-92a5-b0abb01c3009
Open

ThePrimeagen wants to merge 1 commit into
omacom:quattrofrom
ThePrimeagen:fix/2ed81d03-da7c-4892-92a5-b0abb01c3009

Conversation

@ThePrimeagen

Copy link
Copy Markdown
Contributor

When a package install fails at the sudo prompt, the install window still shows green 'Done!' instead of red 'Failed (exit code 1)!', so a failed install looks successful. This happens in bin/omarchy-install-editor-emacs, where the script carries on and launches emacsclient after the package installer has already failed.

Screenshots

Before After
before after

Reproduce

  1. Press Super+Space, type Install, press Enter, type Editor, press Enter, type Emacs, and press Enter.
  2. Wait for the [sudo] password for prime: prompt in the install window.
  3. Press Ctrl+C so the package install fails.
  4. The window shows green 'Done! Press any key to close...' immediately after '-> error installing repo packages', claiming success even though Emacs was not installed.

More cases

VSCode

Before After
before after

Terminal (Alacritty)

Before After
before after

Dropbox

Before After
before after

Also affected

  • bin/omarchy-install-editor-zed: a failed omarchy-pkg-add is followed by theme setup and a background launch, so the window shows 'Done!'; fixed by this change too.
  • bin/omarchy-install-editor-helix: a failed omarchy-pkg-add is followed by config and an alias check that returns 0, so the window shows 'Done!'; fixed by this change too.

Related

The presentation wrapper reports Done/Failed from the install script's
exit code, but these scripts let a failed omarchy-pkg-add/aur-add fall
through to config and launch steps whose success masked the failure.
Add || exit 1 after the package install (and exit 1 in the terminal
script's failure branch) so the wrapper shows Failed and nothing is
launched for a package that was never installed.
@greptile-apps

greptile-apps Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge; no actionable issues were found.

Summary

The six installers now return a failure when package installation fails, so the install window shows “Failed” instead of “Done.”

  • Install windows show failure when package setup stops.

No actionable issues found.

Reviews (1) · Last reviewed commit: "Propagate package-install failures in in..." · Reviewed by Greptile

@omarchybot

Copy link
Copy Markdown
Collaborator

Codex at high effort read the diff, description, comments, surrounding installers, menu callers and base-branch rules. My classification is bug: a failed package step can be hidden by later successful commands, so the presentation window reports success. The classification model, deepseek-v4p1-flash, returned no usable answer, leaving the required two-model classification unsettled. Opus 5.5 High and muse-wonder at high effort answered an availability check only; neither reviewed this PR.

The diff overlaps #17899 in the terminal and editor installers and #9124 in Dropbox; no choice between these fixes has been made. This stops at classification pending maintainer attention. No tests ran, no code was pushed and no labels were added.

@omarchybot omarchybot added the bug Something isn't working label Nov 20, 2026
@omarchybot

Copy link
Copy Markdown
Collaborator

Reviewed at 339569b against quattro, by reading; nothing was run on a worker for this one, for the reason in the next paragraph. The problem is real in the source: each of these six installers ends on a command that succeeds (a backgrounded launch, an echo, a closing if), so a failed omarchy-pkg-add still reaches omarchy-show-done 0 and the window says Done. The change itself is correct as far as it goes, and the two callers that check the result (omarchy-default-terminal, omarchy-default-editor) already do || exit 1, so nothing breaks.

Every file here is already covered by an older open pull request. #17899 (6 November) makes the identical exit 1 change to omarchy-install-terminal and fixes the four editor installers with set -e. Dropbox is covered by #9124 (30 August) and by #17900 (6 November), both with set -e. The four other installers on quattro with the same pattern (omarchy-install-service-nordvpn, -once, -tailscale and omarchy-install-dev-env) are not touched here and are covered by those two. So this adds no file the older ones miss.

Where the approach differs, the older one covers more. || exit 1 on the package line catches a failed install, but a later step that fails (omazed setup, omarchy-theme-set-vscode, the Helix theme link, omarchy-plugin-enable omarchy.dropbox) still ends in Done; set -e reports those too, and it is what 32 of the 47 omarchy-install-* scripts on quattro already use. I read each later step in the editor installers for one that returns non-zero on a good install and found none in this repository (omazed setup and omarchy-install-emacs ship in packages and were not read).

So #17899 is the one that carries the editor and terminal fix, and this pull request is left with the maintainer. Which of #9124 and #17900 carries Dropbox is theirs to choose as well. For ordering: this branch and #17899 each merge cleanly with #18566, which rewrites the launch line at the end of the Emacs, VS Code and Zed installers, but not with each other. #19468 also edits omarchy-install-service-dropbox.

Reviewed by Claude Fable 5.2. Opus 5.5 High and muse-wonder (via pi, thinking high) were given the four diffs and asked which should win without being told my answer: both chose #17899 for the editors and terminal, Opus chose #9124 for Dropbox and muse-wonder #17900, because #9124's bare set -e stops before starting Dropbox when the bar plugin cannot be enabled. That they agree with me is not a guarantee of independence. Labelled bug. Waiting on the maintainer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants