Excluding a file in stage but including it in prime raises an exception

Bug #1734240 reported by Leo Arias
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Snapcraft
New
Undecided
Unassigned

Bug Description

When a snapcraft.yaml excludes a file with the stage keyword, but includes it with the prime keyword, a FileNotFoundError exception is raised.

To reproduce:
mkdir test
cd test
touch conflict-file
Download the attached snapcraft.yaml file and save it in the test directory
Run snapcraft
[...]
FileNotFoundError: [Errno 2] No such file or directory: '/home/ubuntu/tmp/test/stage/conflict-file' -> '/home/ubuntu/tmp/test/prime/conflict-file'
[...]

Full log:
http://paste.ubuntu.com/26031810/

Revision history for this message
Leo Arias (elopio) wrote :
Revision history for this message
Leo Arias (elopio) wrote :

There is an exception in snapcraft/internal/errors.py called PrimeFileConflictError, that apparently should be raised in this case.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.