When executing freight cache, if a dpkg-deb call fails, freight cache still returns success.
For example, when attempting to use freight to add a .deb file that uses zstd compression on a system that does not support zstd compression:
Fails and outputs:
dpkg-deb: error: archive '/var/lib/freight/apt/test/adsys_0.9.2~22.04.1_amd64.deb' uses unknown compression for member 'control.tar.zst', giving up
# [freight] skipping invalid Debian package adsys_0.9.2~22.04.1_amd64.deb
0
Note that it still returns 0.
Expected behavior: If freight cache fails for some reason, it should return non-zero to the OS.
Actual behavior: freight cache exits with 0 even on failure.
When executing
freight cache, if adpkg-debcall fails,freight cachestill returns success.For example, when attempting to use freight to add a .deb file that uses zstd compression on a system that does not support zstd compression:
Fails and outputs:
Note that it still returns 0.
Expected behavior: If
freight cachefails for some reason, it should return non-zero to the OS.Actual behavior:
freight cacheexits with 0 even on failure.