← Back to issue list

repo: use debian.arfile instead of dpkg-deb

View original Github issue

Metadata

Project
snapcraft
Number
#1878
Type
pull request
State
merged
Author
kalikiana
Labels
Created
Updated
Closed

Current evaluation

Merged a fix replacing dpkg-deb with debian.arfile in the repo source handler to bypass a tar and sshfs bug. Reviewers approved the change and suggested extracting shared extraction logic in a follow-up.

Suggested action:

No scores available.

Issue body

- [x] Have you followed the [guidelines for contributing](https://github.com/snapcore/snapcraft/blob/master/CONTRIBUTING.md)? - [x] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)? - [x] If this is a bugfix. Have you checked that there is a bug report open for the issue you are trying to fix on [bug reports](https://bugs.launchpad.net/snapcraft)? - [x] If this is a new feature. Have you discussed the design on the [forum](https://forum.snapcraft.io)? - [x] Have you successfully run `./runtests.sh static`? - [x] Have you successfully run `./runtests.sh unit`? ----- $ cd snapcraft/tests/integration/snaps/python-hello $ SNAPCRAFT_CONTAINER_BUILDS=<remote> snapcraft tar: ./usr/bin/pdb3.5: Cannot utime: No such file or directory tar: ./usr/share/doc/python3.5/changelog.Debian.gz: Cannot utime: No such file or directory tar: Exiting with failure status due to previous errors dpkg-deb: error: subprocess tar returned error exit status 2 Error while provisioning '/home/cris/build_python-hello/parts/python- part/ubuntu/download/python3.5_3.5.2-2ubuntu0~16.04.4_amd64.deb' From my research it seems to be a bug concerning tar, which dpkg-deb is using, in combination with sshfs and the wrong libc. [See the references here](https://github.com/ValveSoftware/steam-for-linux/issues/2358). We're already using debian.arfile in `snapcraft/internal/sources/_deb.py` which is doing pretty much the same thing, except it's not hitting the bug, so I'm porting repo to the same approach.

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.6-35b-a3b Merged a fix replacing dpkg-deb with debian.arfile in the repo source handler to bypass a tar and sshfs bug. Reviewers approved the change and suggested extracting shared extraction logic in a follow-up.
qwen3.6-35b-a3b-mtp-q6 Replaced dpkg-deb with debian.arfile in the repo module to fix a tar and sshfs compatibility bug. Reviewers suggested extracting shared logic, but the change was merged as-is.
qwen3.6-35b-a3b-mtp-q6 Merged changes replacing dpkg-deb with debian.arfile in the repo source handler to bypass a tar bug on sshfs. Reviewers suggested extracting shared logic, but the update was merged as-is.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#2111 repo: rollback to using dpkg-deb for deb extraction snapcraft merged Merged a revert restoring dpkg-deb for deb extraction after debian.arfile caused severe performance regressions. The change addresses LP #1767119 by switching back to the faster dpkg-deb tool, resolving the build slowdown.
78%
#1729 sources: use arfile to extract debs snapcraft merged Merged a fix replacing DebFile with ArFile to extract .deb packages, resolving apt_inst import failures on non-Debian hosts. Approved and merged after passing CI checks.
78%
#269 sources: support "deb" sources craft-parts merged Merged. Adds deb source support by unpacking packages via dpkg-deb and refactors extract_deb() for reuse. Resolves CRAFT-117, approved by one reviewer, passes CI, and changes +289/-10 lines across seven files.
70%