← Back to issue list

Snapcraft 7 silently ignores any files ending in *.snap when the source is a folder

View original Launchpad issue

Metadata

Project
snapcraft
Number
#1990166
Type
issue
State
open
Author
~itrue
Labels
Created
2022-09-19 15:33:42.499693+00:00
Updated
2022-09-19 16:19:33.708563+00:00
Closed

Current evaluation

Snapcraft 7 silently omits .snap files from source directories during builds. Reproducible via nil plugin override-build failure. Open, inactive for over three years with zero comments. Needs triage, a fix, or a warning to prevent silent data loss.

Suggested action: close stale

Reason: The issue is over 3.7 years old with zero maintainer engagement, reflecting a very high staleness score. While it is a well-structured bug report (low support_request score), Snapcraft has significantly evolved since version 7, and the reported behavior is likely irrelevant to current supported versions. Given the prolonged inactivity and version obsolescence, closing as stale is appropriate.

Staleness: 95 Complexity: 40 Confidence: 85 Support Request: 5

Issue body

Any files which end in *.snap are not copied to the part/x/src directory, as can be seen from this minimal example: snapcraft.yaml: name: my-snap-name base: core22 version: '0.1' summary: Single-line elevator pitch for your amazing snap description: Test grade: devel confinement: devmode parts: my-part: plugin: nil source: test override-build: | cp ${CRAFT_PART_SRC}/test.snap ${CRAFT_PART_INSTALL}/test.snap --- Snapcraft output: itrue@lxc-jammy:~/tmp/test-snap$ sudo snapcraft --verbose --destructive-mode Starting Snapcraft 7.1.3 Logging execution to '/root/.cache/snapcraft/log/snapcraft-20220919-153058.032639.log' Running on amd64 for amd64 Initializing parts lifecycle Executing parts lifecycle... Executing parts lifecycle: skip pull my-part (already ran) Executing action Executed: skip pull my-part (already ran) Executing parts lifecycle: skip overlay my-part (already ran) Executing action Executed: skip overlay my-part (already ran) Executing parts lifecycle: build my-part Executing action :: + cp /home/itrue/tmp/test-snap/parts/my-part/src/test.snap /home/itrue/tmp/test-snap/parts/my-part/install/test.snap :: cp: cannot stat '/home/itrue/tmp/test-snap/parts/my-part/src/test.snap': No such file or directory 'override-build' in part 'my-part' failed with code 1. Review the scriptlet and make sure it's correct. Full execution log: '/root/.cache/snapcraft/log/snapcraft-20220919-153058.032639.log' --- Source folder contents: itrue@lxc-jammy:~/tmp/test-snap$ ls test test.notasnap test.snap --- parts src folder contents: itrue@lxc-jammy:~/tmp/test-snap$ ls parts/my-part/src/ test.notasnap --- Please either copy all files in the source directory, or at least add a warning to say that these files are not being copied, rather than silently not doing it.

Evaluation history

Date Model Scores Action Summary
2026-06-19 05:48:34.699376+00:00 qwen3.6-35b-a3b-mtp-q6
Staleness: 95
Complexity: 40
Confidence: 85
Support Request: 5
close stale Snapcraft 7 silently omits .snap files from source directories during builds. Reproducible via nil plugin override-build failure. Open, inactive for over three years with zero comments. Needs triage, a fix, or a warning to prevent silent data loss.
2026-06-19 05:45:03.163500+00:00 pending