Skip to content

fix: don't apply default plugs or layout to classic-confinement core24 snaps - #10060

Merged
mmaietta merged 3 commits into
masterfrom
fix/10057-core24-classic-confinement
Aug 17, 2026
Merged

fix: don't apply default plugs or layout to classic-confinement core24 snaps#10060
mmaietta merged 3 commits into
masterfrom
fix/10057-core24-classic-confinement

Conversation

@claude

@claude claude Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Requested via Slack thread

Before: building a core24 snap with confinement: classic still generated the default content-snap plugs (gnome-46-2404, gtk-3-themes, icon-themes, sound-themes, gpu-2404), the injected browser-support plug, app-level default plugs, and the default layout in snapcraft.yaml. The snap store review rejects classic snaps that declare plugs or layout, so classic core24 snaps could not pass review.

After: classic-confinement core24 snaps declare no plugs (root or app level) and no layout, restoring the guard the legacy builder has had since #2730. The core24 rewrite (#9517) lost this guard. Strict-confinement output is unchanged.

Details:

  • Explicitly configured plugs/layout are still honored under classic, but a log.warn now notes the store review is likely to reject them.
  • Because classic no longer gets the injected browser-support (allow-sandbox) plug, the generated launcher script now passes --no-sandbox and the unused setuid chrome-sandbox helper is stripped from the staged app — same runtime behavior the legacy builder applies to classic snaps.
  • Plug/layout resolution in SnapCore24 was refactored from nested ternaries into explicit early-return helpers (resolvePlugs, resolveLayout, buildDefaultRootPlugs); behavior is otherwise identical.
  • The snapcraftTest snapshot entry for the new classic test was written by hand; CI will correct it if it is off.

Fixes #10057


Generated by Claude Code

@changeset-bot

changeset-bot Bot commented Aug 4, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: c9cc82b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 8 packages
Name Type
app-builder-lib Patch
dmg-builder Patch
electron-builder-squirrel-windows Patch
electron-builder Patch
electron-forge-maker-appimage Patch
electron-forge-maker-nsis-web Patch
electron-forge-maker-nsis Patch
electron-forge-maker-snap Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Comment thread packages/app-builder-lib/src/targets/linux/snap/core24.ts Outdated
@mmaietta
mmaietta marked this pull request as ready for review August 6, 2026 15:07
@mmaietta
mmaietta merged commit e37cb17 into master Aug 17, 2026
61 of 62 checks passed
@mmaietta
mmaietta deleted the fix/10057-core24-classic-confinement branch August 17, 2026 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Core24 Snap Classic: Unnecessary Plugs and layout

2 participants