Repository navigation
fix(cli): debian and ubuntu users get the .deb from the app download link - #9136
Conversation
jrusso1020
left a comment
There was a problem hiding this comment.
Reviewed at 7298a92. Full diff read (2 files, +30 −2), plus detectLinuxDistro and its callers of desktopDownloadUrl (desktopHint, the open answer, mountDesktopRoutes). Nothing run locally.
The change is right. All three callers go through desktopDownloadUrl, the probe runs only when the platform is Linux, and an unreadable /etc/os-release falls back to the AppImage link as before. The body carries the "fails without the fix:" line and the named test exists and pins both the .deb and the AppImage cases.
One thing holds it, caused by this change: Comments is red at this head:
RAISED comment share: packages/cli/src/utils/desktopApp.ts is 4.6% (16/347), at the base 4.4% (15/344). 1 comment line(s) added.
That is the one-line comment above linuxDownload. Drop it or fold the reason into a name (the PR body already carries the why). I approve as soon as Comments is green; no other change needed.
Need: yes · Size: fits · Reuse: yes, the existing os-release reader · Simpler: no · Structure: fine
Risk: low. Not checked by me: that the download route serves a .deb for every architecture the AppImage link covers.
— Rames
Edit accuracy: accurate 275 (base branch 275), smooth 50 of thoseThe gate passes. Quarantined, measured but not gated (0) |
jrusso1020
left a comment
There was a problem hiding this comment.
Reviewed at bb96cf7. Delta since 7298a92 compared by bytes: the added comment line is gone and the helper is renamed debOnDebianFamilyElseAppImage, nothing else. Behaviour is the same as the head I read in full.
Prior point: resolved. The file no longer adds a comment line, so the comment-share check has nothing to raise; Comments was still pending when I looked, not red. Nothing run locally.
Need: yes · Size: fits · Reuse: yes, the existing os-release reader · Simpler: no · Structure: fine
Risk: low. Not checked by me: that the download route serves a .deb for every architecture the AppImage link covers.
— Rames
What
On Debian, Ubuntu and their derivatives, the CLI's "download the desktop app" link now points to the
.deb. Other Linux systems still get the AppImage.Why
On Ubuntu 24.04 and later the AppImage does not start. The system blocks unprivileged user namespaces by default (
kernel.apparmor_restrict_unprivileged_userns=1), and an AppImage'schrome-sandboxcan't be setuid root. So Chromium aborts before the window opens, with "The SUID sandbox helper binary was found, but is not configured correctly". The.debinstallschrome-sandboxsetuid root and loads an AppArmor profile, so it starts there.The CLI handed every Linux user
?os=linux, the AppImage. The site's own default for a Linux browser is already the.deb.Related work
The download route already serves
os=deb(the.deb) andos=linux(the AppImage).How
desktopDownloadUrlasksdetectLinuxDistro()(the CLI's existing/etc/os-releasereader inbrowser/linuxDeps.ts), only on Linux.debianfamily (Debian, Ubuntu, Mint, Pop!_OS, elementary, Kali) getsos=deb. Any other family, or an unreadable/etc/os-release, keepsos=linux.open, and the browser editor's "Open in desktop" route.Test plan
fails without the fix:
desktopApp.test.ts"offers Debian and Ubuntu the .deb, other Linux systems the AppImage" (against main'sdesktopApp.tsthe Debian case getsos=linux).ffmpeg.test.tsdoes. With the change,desktopApp.test.tsanddesktopRoutes.test.tspass 56/56, 3 runs in a row..debcarries the setuidchrome-sandboxand an AppArmor profile in itspostinst. I didn't install the.debhere (no root on that machine)..deb.Not exercised: a real Fedora or Arch machine following the link; their family resolves to
os=linuxas before.