← Back to issue list

Built executable is not copied to prime/bin/

View original Launchpad issue

Metadata

Project
snapcraft (launchpad)
Number
#1797378
Type
issue
State
open
Author
~sangbum
Labels
Created
Updated
Closed

Current evaluation

Snapcraft 2.43.1+18.4 crashes during prime with FileNotFoundError when an app's command points to a file (prettier) that was not copied to prime/bin/; build/bin/ only contained prettier.js. Reported 8 years ago, no maintainer activity, 0 comments, unlabelled.

Suggested action: close stale

Reason: The issue is 2881 days (~8 years) old with zero comments, no labels, and no maintainer interaction. It targets snapcraft 2.43.1+18.4, a long-EOL 2.x release whose code path (snapcraft/internal/meta/_snap_packaging.py) no longer exists in the current codebase (now snapcraft/meta/snap_packaging.py). A similar Launchpad bug (1884683) confirms the same 2.x FileNotFoundError pattern is considered obsolete. The underlying problem — an app command referencing a file not present in prime/bin/ — is a user configuration error (the build only produced prettier.js, not prettier), not a snapcraft bug, and the current codebase has been entirely restructured since.

Impact: 30 Quick Win: 21.0 Staleness: 95 Complexity: 30 Confidence: 70 Support Request: 40

Issue body

Snapcraft crashed with following error while priming: Sorry, an error occurred in Snapcraft: Traceback (most recent call last): File "/usr/bin/snapcraft", line 11, in <module> load_entry_point('snapcraft==2.43.1+18.4', 'console_scripts', 'snapcraft')() File "/usr/lib/python3/dist-packages/click/core.py", line 722, in __call__ return self.main(*args, **kwargs) File "/usr/lib/python3/dist-packages/click/core.py", line 697, in main rv = self.invoke(ctx) File "/usr/lib/python3/dist-packages/click/core.py", line 1043, in invoke return Command.invoke(self, ctx) File "/usr/lib/python3/dist-packages/click/core.py", line 895, in invoke return ctx.invoke(self.callback, **ctx.params) File "/usr/lib/python3/dist-packages/click/core.py", line 535, in invoke return callback(*args, **kwargs) File "/usr/lib/python3/dist-packages/click/decorators.py", line 17, in new_func return f(get_current_context(), *args, **kwargs) File "/usr/lib/python3/dist-packages/snapcraft/cli/_runner.py", line 93, in run ctx.forward(lifecyclecli.commands["snap"]) File "/usr/lib/python3/dist-packages/click/core.py", line 553, in forward return self.invoke(cmd, **kwargs) File "/usr/lib/python3/dist-packages/click/core.py", line 535, in invoke return callback(*args, **kwargs) File "/usr/lib/python3/dist-packages/snapcraft/cli/lifecycle.py", line 136, in snap project = _execute(steps.PRIME, parts=[], **kwargs) File "/usr/lib/python3/dist-packages/snapcraft/cli/lifecycle.py", line 35, in _execute lifecycle.execute(step, project_config, parts) File "/usr/lib/python3/dist-packages/snapcraft/internal/lifecycle/_runner.py", line 90, in execute executor.run(step, part_names) File "/usr/lib/python3/dist-packages/snapcraft/internal/lifecycle/_runner.py", line 196, in run self._create_meta(step, processed_part_names) File "/usr/lib/python3/dist-packages/snapcraft/internal/lifecycle/_runner.py", line 359, in _create_meta self.config.validator.schema, File "/usr/lib/python3/dist-packages/snapcraft/internal/meta/_snap_packaging.py", line 109, in create_snap_packaging packaging.write_snap_yaml() File "/usr/lib/python3/dist-packages/snapcraft/internal/meta/_snap_packaging.py", line 312, in write_snap_yaml snap_yaml = self._compose_snap_yaml() File "/usr/lib/python3/dist-packages/snapcraft/internal/meta/_snap_packaging.py", line 468, in _compose_snap_yaml snap_yaml["apps"] = self._wrap_apps(self._config_data["apps"]) File "/usr/lib/python3/dist-packages/snapcraft/internal/meta/_snap_packaging.py", line 567, in _wrap_apps self._wrap_app(app, apps[app]) File "/usr/lib/python3/dist-packages/snapcraft/internal/meta/_snap_packaging.py", line 575, in _wrap_app app[k] = self._wrap_exe(app[k], "{}-{}".format(k, name)) File "/usr/lib/python3/dist-packages/snapcraft/internal/meta/_snap_packaging.py", line 546, in _wrap_exe with open(exepath, "rb") as exefile: FileNotFoundError: [Errno 2] No such file or directory: '/home/sangbum/Projects/prettier-snap/snap/prime/bin/prettier' * build/bin/ contained prettier.js but no file named prettier

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.8-27b
Impact: 30
Quick Win: 21.0
Staleness: 95
Complexity: 30
Confidence: 70
Support Request: 40
close stale Snapcraft 2.43.1+18.4 crashes during prime with FileNotFoundError when an app's command points to a file (prettier) that was not copied to prime/bin/; build/bin/ only contained prettier.js. Reported 8 years ago, no maintainer activity, 0 comments, unlabelled.
qwen/qwen3.6-35b-a3b
Staleness: 98
Complexity: 35
Confidence: 92
Support Request: 15
close stale Snapcraft v2.43.1 crashes during prime step because a built executable is missing from prime/bin/. No maintainer interaction or activity in ~7.8 years.
qwen/qwen3.6-35b-a3b
Staleness: 98
Complexity: 30
Confidence: 95
Support Request: 10
close stale Snapcraft v2.43.1 crashes during prime step due to missing executable. Unaddressed for ~8 years with no maintainer interaction.
qwen3.6-35b-a3b-mtp-q6
Staleness: 95
Complexity: 15
Confidence: 90
Support Request: 20
close stale Snapcraft 2.43.1 crashes during the prime step because a built executable is not copied to prime/bin/. The report is from 2018, lacks labels or comments, and targets a deprecated version.
qwen3.6-35b-a3b-mtp-q6
Staleness: 98
Complexity: 40
Confidence: 90
Support Request: 10
close stale Snapcraft 2.43.1 crashes during priming due to a missing executable in prime/bin/. The issue is over 7 years old, lacks maintainer interaction, and targets a long-unsupported version.

Update history

No update history recorded yet.

Related work

  • Related To: snapcraft#1884683 (confidence 55%)

    Similar Launchpad bug: snapcraft 2.43.1+18.4 FileNotFoundError for a missing app command in prime; same EOL 2.x code path.

Related issues

Issue Project State Summary Similarity
#1812435 python snap fails to build no such file or directory in prime/bin snapcraft (launchpad) open Snapcraft 2.43.1 crashes with FileNotFoundError when an app's command is missing from prime/bin during snap packaging. Reported 2782 days ago with no comments, labels, or maintainer response. The legacy code path no longer exists in the current codebase.
81%
#1795171 snapcraft fail to find built executable under prime $SNAP snapcraft (launchpad) closed Closed without resolution or comments, likely abandoned. The issue reported a FileNotFoundError when Snapcraft failed to expand the $SNAP variable in the prime directory path during build.
76%
#1884683 snapcraft fail app snapcraft (launchpad) open Snapcraft 2.43.1+18.4 crashes with FileNotFoundError when an app's command points to /bin/Sastreria, which is missing from the prime directory. No comments or labels; the affected 2.x version is long EOL and the code path no longer exists.
74%
#1797795 An error occurred building hello world Snapcraft snapcraft (launchpad) open Snapcraft 2.43.1 prime crashes with FileNotFoundError when app command points to bin/hello, but only gnu-bash part is built so the binary doesn't exist. User configuration error, 7.9 years old, 0 comments, no labels.
73%
#1830520 Sorry, an error occurred in Snapcraft: snapcraft (launchpad) open Snapcraft 2.43.1 (2019) crashed with FileNotFoundError wrapping app command spx_service missing from the prime dir during a Launchpad build. No maintainer activity in 7+ years; the 2.x code path no longer exists and the root cause is user snapcraft.yaml config.
72%