Issue Uploading Snap After First Revision

Currently using latest snapcraft and hitting an error while uploading after doing one revision.

The command I am using is snapcraft upload --release=stable andrewgoatsnap_0.2_amd64.snap If you look at the store you can see my first revision completed fine. I did change the version in my snapcraft.yaml to be 0.2 from 0.1 as well as changed the summary. It seems to be an issue finding the delta between two files. Anyone have any advice about this error? -

Sorry, an error occurred in Snapcraft: [Errno 8] Exec format error: ‘/snap/snapcraft/7010/usr/bin/xdelta3’ We would appreciate it if you anonymously reported this issue. No other data than the traceback and the version of snapcraft in use will be sent. Would you like to send this error data? (Yes/No/Always/View) [no]: view Traceback (most recent call last): File “/snap/snapcraft/7010/bin/snapcraft”, line 8, in sys.exit(run()) File “/var/lib/snapd/snap/snapcraft/7010/lib/python3.8/site-packages/click/core.py”, line 1137, in call return self.main(*args, **kwargs) File “/var/lib/snapd/snap/snapcraft/7010/lib/python3.8/site-packages/click/core.py”, line 1062, in main rv = self.invoke(ctx) File “/var/lib/snapd/snap/snapcraft/7010/lib/python3.8/site-packages/click/core.py”, line 1668, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File “/var/lib/snapd/snap/snapcraft/7010/lib/python3.8/site-packages/click/core.py”, line 1404, in invoke return ctx.invoke(self.callback, **ctx.params) File “/var/lib/snapd/snap/snapcraft/7010/lib/python3.8/site-packages/click/core.py”, line 763, in invoke return __callback(*args, **kwargs) File “/var/lib/snapd/snap/snapcraft/7010/lib/python3.8/site-packages/snapcraft/cli/store.py”, line 180, in upload snap_name, snap_revision = snapcraft.upload(snap_file, channel_list) File “/var/lib/snapd/snap/snapcraft/7010/lib/python3.8/site-packages/snapcraft/_store.py”, line 711, in upload result = _upload_delta( File “/var/lib/snapd/snap/snapcraft/7010/lib/python3.8/site-packages/snapcraft/_store.py”, line 781, in _upload_delta delta_filename = xdelta_generator.make_delta() File “/var/lib/snapd/snap/snapcraft/7010/lib/python3.8/site-packages/snapcraft/internal/deltas/_deltas.py”, line 192, in make_delta proc = subprocess.Popen( File “/var/lib/snapd/snap/snapcraft/7010/usr/lib/python3.8/subprocess.py”, line 858, in init self._execute_child(args, executable, preexec_fn, close_fds, File “/var/lib/snapd/snap/snapcraft/7010/usr/lib/python3.8/subprocess.py”, line 1704, in _execute_child raise child_exception_type(errno_num, err_msg, err_filename) OSError: [Errno 8] Exec format error: ‘/snap/snapcraft/7010/usr/bin/xdelta3’

Hi. Try and save what’s in this path for later debugging and clear it before trying again: ~/.cache/snapcraft/projects/andrewgoatsnap/

1 Like

Hey let me try to rm the directory and trying again but this is the result.

It did look like it worked 1 time @sergiusens after removing but failed again once I uploaded once and tried again. My guess is I need to remove that folder everytime I upload but not sure why thats the case.

1 Like

I’m having the same issue here. I’m using a RHEL 7.9 box with snapcraft (latest/stable) and LXD installed. Once I remove the cache, things begin working again!

1 Like

We will have to do some research and figure out why this is happening. Will get back to you with a better solution once done.

Do you mind sharing details about the system where this is happening? (i.e.; /etc/os-release, snap version). Do you mind trying to reproduce the upload while using snapcraft from the 5.x track?

Hey @sergiusens Yes I was getting a different error with 5.x/4.x I’ll try to downgrade and share that error with you in a bit. What do you mean exactly where this happening? Are you asking for details about my personnel OS setup?

Yes, I was asking for information like what is os-release and the output of snap info

Here is the information -

OS Info

NAME=“Oracle Linux Server” VERSION=“7.9” ID=“ol” ID_LIKE=“fedora” VARIANT=“Server” VARIANT_ID=“server” VERSION_ID=“7.9” PRETTY_NAME=“Oracle Linux Server 7.9” ANSI_COLOR=“0;31” CPE_NAME=“cpe:/o:oracle:linux:7:9:server” HOME_URL=“https://linux.oracle.com/” BUG_REPORT_URL=“https://bugzilla.oracle.com/

ORACLE_BUGZILLA_PRODUCT=“Oracle Linux 7” ORACLE_BUGZILLA_PRODUCT_VERSION=7.9 ORACLE_SUPPORT_PRODUCT=“Oracle Linux” ORACLE_SUPPORT_PRODUCT_VERSION=7.9

Snap Version

snap 2.52-1.el7 snapd 2.52-1.el7 series 16 ol 7.9 kernel 5.4.17-2136.302.7.2.1.el7uek.x86_64

snapcraft version

snapcraft, version 6.0.2