← Back to issue list

Building snaps with `kde-neon` extension is not working

View original Github issue

Metadata

Project
snapcraft-rocks
Number
#37
Type
issue
State
open
Author
hhromic
Labels
Created
Updated
Closed

Current evaluation

Snapcraft Docker images (ghcr.io/canonical/snapcraft:8_core22) fail to build snaps using the kde-neon extension: 'unable to determine source type of /usr/share/snapcraft/extensions/desktop/kde-neon'. Root cause is snapcraft's get_extensions_data_dir() hard-coding sys.prefix, which resolves to the wrong path in the Docker image. Confirmed still broken for core24/kde-neon-6 and GNOME in 2025.

Suggested action: keep open

Reason: A maintainer (tigarmo) acknowledged the report and confirmed extensions 'probably need to do some work to support', and the reporter traced the root cause to snapcraft's get_extensions_data_dir() hard-coding sys.prefix. The issue was re-confirmed still broken in 2025 (core24/kde-neon-6 and GNOME), so it remains a valid, open bug. It is not stale-irrelevant and not a support question, so it should stay open pending a fix.

Impact: 60 Quick Win: 27.0 Staleness: 45 Complexity: 55 Confidence: 70 Support Request: 15

Issue body

Hello, I recently found out about this repository and its intention to be the official way to build Snap packages in Docker. I tried to build our Snap packages using `ghcr.io/canonical/snapcraft:8_core22` but sadly it did not work as expected. The problem seems to be when using the `kde-neon` extension. Consider the following `snap/snapcraft.yaml` example adapted from the [official guide for Qt5/KF applications](https://snapcraft.io/docs/qt5-kde-applications): ```yaml name: kcalc version: 19.08.0 grade: stable adopt-info: kcalc confinement: strict base: core22 apps: kcalc: common-id: org.kde.kcalc.desktop command: kcalc extensions: - kde-neon plugs: - home - opengl - network - network-bind - pulseaudio slots: session-dbus-interface: interface: dbus name: org.kde.kcalc.desktop bus: session parts: kcalc: parse-info: - usr/share/metainfo/org.kde.kcalc.appdata.xml plugin: cmake build-snaps: - kf5-5-111-qt-5-15-11-core22-sdk build-packages: - libmpfr-dev - libgmp-dev - libkf5doctools-dev stage-packages: - libmpfr6 - libgmp10 source: https://download.kde.org/stable/applications/19.08.0/src/kcalc-19.08.0.tar.xz cmake-parameters: - "-DKDE_INSTALL_USE_QT_SYS_PATHS=ON" - "-DCMAKE_INSTALL_PREFIX=/usr" - "-DCMAKE_BUILD_TYPE=Release" - "-DENABLE_TESTING=OFF" - "-DBUILD_TESTING=OFF" - "-DKDE_SKIP_TEST_SETTINGS=ON" ``` The above Snapcraft file does not build using the `ghcr.io/canonical/snapcraft:8_core22` image: ``` $ docker run -it -v `pwd`:/project ghcr.io/canonical/snapcraft:8_core22 2024-04-28T21:36:27.568Z [pebble] Started daemon. 2024-04-28T21:36:27.598Z [pebble] POST /v1/services 18.095676ms 202 2024-04-28T21:36:27.599Z [pebble] Started default services with change 1. 2024-04-28T21:36:27.610Z [pebble] Service "snapcraft" starting: /bin/run-snapcraft.sh [ pack ] 2024-04-28T21:36:27.634Z [snapcraft] 2024-04-28T21:36:27.635Z [snapcraft] WARNING: apt does not have a stable CLI interface. Use with caution in scripts. 2024-04-28T21:36:27.635Z [snapcraft] 2024-04-28T21:36:27.925Z [snapcraft] Get:1 http://archive.ubuntu.com/ubuntu jammy InRelease [270 kB] 2024-04-28T21:36:27.983Z [snapcraft] Get:2 http://security.ubuntu.com/ubuntu jammy-security InRelease [110 kB] 2024-04-28T21:36:28.491Z [snapcraft] Get:3 http://archive.ubuntu.com/ubuntu jammy-updates InRelease [119 kB] 2024-04-28T21:36:28.640Z [snapcraft] Get:4 http://archive.ubuntu.com/ubuntu jammy-backports InRelease [109 kB] 2024-04-28T21:36:28.787Z [snapcraft] Get:5 http://archive.ubuntu.com/ubuntu jammy/multiverse amd64 Packages [266 kB] 2024-04-28T21:36:28.939Z [snapcraft] Get:6 http://archive.ubuntu.com/ubuntu jammy/universe amd64 Packages [17.5 MB] 2024-04-28T21:36:29.099Z [snapcraft] Get:7 http://security.ubuntu.com/ubuntu jammy-security/main amd64 Packages [1755 kB] 2024-04-28T21:36:32.254Z [snapcraft] Get:8 http://security.ubuntu.com/ubuntu jammy-security/multiverse amd64 Packages [44.7 kB] 2024-04-28T21:36:32.291Z [snapcraft] Get:9 http://security.ubuntu.com/ubuntu jammy-security/restricted amd64 Packages [2265 kB] 2024-04-28T21:36:32.380Z [snapcraft] Get:10 http://archive.ubuntu.com/ubuntu jammy/restricted amd64 Packages [164 kB] 2024-04-28T21:36:32.391Z [snapcraft] Get:11 http://archive.ubuntu.com/ubuntu jammy/main amd64 Packages [1792 kB] 2024-04-28T21:36:32.705Z [snapcraft] Get:12 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 Packages [2035 kB] 2024-04-28T21:36:33.301Z [snapcraft] Get:13 http://archive.ubuntu.com/ubuntu jammy-updates/universe amd64 Packages [1370 kB] 2024-04-28T21:36:33.528Z [snapcraft] Get:14 http://archive.ubuntu.com/ubuntu jammy-updates/restricted amd64 Packages [2339 kB] 2024-04-28T21:36:33.832Z [snapcraft] Get:15 http://archive.ubuntu.com/ubuntu jammy-updates/multiverse amd64 Packages [51.1 kB] 2024-04-28T21:36:33.846Z [snapcraft] Get:16 http://archive.ubuntu.com/ubuntu jammy-backports/main amd64 Packages [81.0 kB] 2024-04-28T21:36:33.846Z [snapcraft] Get:17 http://archive.ubuntu.com/ubuntu jammy-backports/universe amd64 Packages [31.9 kB] 2024-04-28T21:36:34.320Z [snapcraft] Get:18 http://security.ubuntu.com/ubuntu jammy-security/universe amd64 Packages [1077 kB] 2024-04-28T21:36:37.034Z [snapcraft] Fetched 31.4 MB in 9s (3359 kB/s) 2024-04-28T21:36:37.034Z [snapcraft] Reading package lists... 2024-04-28T21:36:39.910Z [snapcraft] Building dependency tree... 2024-04-28T21:36:40.215Z [snapcraft] Reading state information... 2024-04-28T21:36:40.273Z [snapcraft] 15 packages can be upgraded. Run 'apt list --upgradable' to see them. 2024-04-28T21:36:45.918Z [snapcraft] Starting Snapcraft 8.0.5 2024-04-28T21:36:45.918Z [snapcraft] Logging execution to '/root/.local/state/snapcraft/log/snapcraft-20240428-213645.910384.log' 2024-04-28T21:36:45.957Z [snapcraft] Running on amd64 for amd64 2024-04-28T21:36:45.966Z [snapcraft] Initializing parts lifecycle 2024-04-28T21:36:45.981Z [snapcraft] Failed to pull source: unable to determine source type of '/usr/share/snapcraft/extensions/desktop/kde-neon'. 2024-04-28T21:36:45.987Z [snapcraft] Full execution log: '/root/.local/state/snapcraft/log/snapcraft-20240428-213645.910384.log' 2024-04-28T21:36:46.344Z [pebble] Service "snapcraft" stopped unexpectedly with code 1 2024-04-28T21:36:46.344Z [pebble] Service "snapcraft" on-failure action is "shutdown", triggering failure shutdown 2024-04-28T21:36:46.344Z [pebble] Server exiting! ``` The same Snapcraft file does start building correctly in Ubuntu with the regular `snapcraft` command: ``` $ snapcraft --use-lxd --verbose Starting Snapcraft 8.0.5 Logging execution to '/home/hhromic/.local/state/snapcraft/log/snapcraft-20240428-223554.190257.log' Running on amd64 for amd64 Launching instance... Starting instance Starting Snapcraft 8.0.5 Logging execution to '/tmp/snapcraft.log' Running on amd64 for amd64 Initializing parts lifecycle Installing build-packages Installing build-snaps Pulling kcalc Fetching stage-packages Pulling kde-neon/sdk Building kcalc :: + cmake /root/parts/kcalc/src -G 'Unix Makefiles' -DKDE_INSTALL_USE_QT_SYS_PATHS=ON -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release -DENABLE_TESTING=OFF -DBUILD_TESTING=OFF -DKDE_SKIP_TEST_SETTINGS=ON :: -- The C compiler identification is GNU 11.2.0 :: -- The CXX compiler identification is GNU 11.2.0 :: -- Detecting C compiler ABI info :: -- Detecting C compiler ABI info - done :: -- Check for working C compiler: /usr/bin/cc - skipped :: -- Detecting C compile features :: -- Detecting C compile features - done :: -- Detecting CXX compiler ABI info :: -- Detecting CXX compiler ABI info - done ... ``` > **Warning:** The kcalc build itself does not actually succeed in this example, but at least it does start building. Is there something I'm doing wrong when using the `ghcr.io/canonical/snapcraft:8_core22` image or Snapcraft files using extensions is not yet supported by the images in this repository?

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.8-27b
Impact: 60
Quick Win: 27.0
Staleness: 45
Complexity: 55
Confidence: 70
Support Request: 15
keep open Snapcraft Docker images (ghcr.io/canonical/snapcraft:8_core22) fail to build snaps using the kde-neon extension: 'unable to determine source type of /usr/share/snapcraft/extensions/desktop/kde-neon'. Root cause is snapcraft's get_extensions_data_dir() hard-coding sys.prefix, which resolves to the wrong path in the Docker image. Confirmed still broken for core24/kde-neon-6 and GNOME in 2025.
qwen/qwen3.6-35b-a3b
Staleness: 75
Complexity: 30
Confidence: 85
Support Request: 10
needs triage Reports kde-neon extension build failures in the snapcraft Docker image due to a hardcoded Python path mismatch. Confirmed unresolved in newer versions, awaiting maintainer investigation.
qwen3.6-35b-a3b-mtp-q6
Staleness: 75
Complexity: 40
Confidence: 85
Support Request: 10
keep open Bug in Snapcraft Docker/Rocks images where extensions fail to load due to incorrect Python sys.prefix path resolution. Validated across multiple extensions and Snapcraft versions, but remains unaddressed.
qwen3.6-35b-a3b-mtp-q6
Staleness: 80
Complexity: 45
Confidence: 75
Support Request: 5
needs triage Snapcraft Docker images fail to locate extensions due to incorrect sys.prefix path resolution. The issue persists across versions and remains open pending a fix.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#1881963 extension: kde-neon fails on arm64 snapcraft (launchpad) closed Abandoned due to inactivity. The kde-neon extension fails on arm64 because the kde-frameworks-5-core18 snap lacks arm64 builds, causing snapcraft to fail during prerequisite installation.
72%
#5128 KDE Neon 6 broken on arm64 snapcraft open kde-neon-6 extension fails on arm64 because the kf6-core22 content snap is missing Qt6 libraries (73MB vs 2GB amd64). Filed 682 days ago, no maintainer response, only 1 user comment. Root cause is in the external KDE content snap, not snapcraft code.
71%