bzr-bd chokes if tarball .asc in directory

Bug #1587659 reported by Jeremy Bícha
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
bzr-builddeb (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Some Debian packages are including .asc files with the original source tarballs. .asc are signature files. bzr-builddeb doesn't know what a vlc_2.2.3.orig.tar.xz.asc and fails.

Below is what I got when I tried to build vlc today on Ubuntu yakkety from Debian sid source. My normal workflow uses packaging-only branches to make sure there aren't any inadvertent changes outside the debian/ directory.

$ dget http://httpredir.debian.org/debian/pool/main/v/vlc/vlc_2.2.3-2.dsc
dget: retrieving http://httpredir.debian.org/debian/pool/main/v/vlc/vlc_2.2.3-2.dsc
  % Total % Received % Xferd Average Speed Time Time Time Current
                                 Dload Upload Total Spent Left Speed
  0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 5950 100 5950 0 0 326 0 0:00:18 0:00:18 --:--:-- 1443
dget: retrieving http://httpredir.debian.org/debian/pool/main/v/vlc/vlc_2.2.3.orig-ffmpeg-2-8-7.tar.xz
  % Total % Received % Xferd Average Speed Time Time Time Current
                                 Dload Upload Total Spent Left Speed
  0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 7036k 100 7036k 0 0 952k 0 0:00:07 0:00:07 --:--:-- 920k
dget: retrieving http://httpredir.debian.org/debian/pool/main/v/vlc/vlc_2.2.3.orig.tar.xz
  % Total % Received % Xferd Average Speed Time Time Time Current
                                 Dload Upload Total Spent Left Speed
  0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 20.8M 100 20.8M 0 0 1543k 0 0:00:13 0:00:13 --:--:-- 1719k
dget: retrieving http://httpredir.debian.org/debian/pool/main/v/vlc/vlc_2.2.3.orig.tar.xz.asc
  % Total % Received % Xferd Average Speed Time Time Time Current
                                 Dload Upload Total Spent Left Speed
  0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 173 100 173 0 0 122 0 0:00:01 0:00:01 --:--:-- 3145
dget: retrieving http://httpredir.debian.org/debian/pool/main/v/vlc/vlc_2.2.3-2.debian.tar.xz
  % Total % Received % Xferd Average Speed Time Time Time Current
                                 Dload Upload Total Spent Left Speed
  0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 73620 100 73620 0 0 137k 0 --:--:-- --:--:-- --:--:-- 137k
vlc_2.2.3-2.dsc:
      Good signature found
   validating vlc_2.2.3.orig-ffmpeg-2-8-7.tar.xz
   validating vlc_2.2.3.orig.tar.xz
   validating vlc_2.2.3.orig.tar.xz.asc
   validating vlc_2.2.3-2.debian.tar.xz
All files validated successfully.
dpkg-source: info: extracting vlc in vlc-2.2.3
dpkg-source: info: unpacking vlc_2.2.3.orig.tar.xz
dpkg-source: info: unpacking vlc_2.2.3.orig-ffmpeg-2-8-7.tar.xz
dpkg-source: info: unpacking vlc_2.2.3-2.debian.tar.xz
dpkg-source: info: applying frenchtv-links.patch
dpkg-source: info: applying zsh-completion.patch
dpkg-source: info: applying fix-translation.patch
dpkg-source: info: applying drop-check-qt-check.patch
dpkg-source: info: applying the-Hurd-also-uses-the-.so-extension-for-libraries.patch
dpkg-source: info: applying Fix-Hurd-build.patch
dpkg-source: info: applying g711-fix-dangling-pointer-fixes-16909.patch
dpkg-source: info: applying adpcm-reject-invalid-QuickTime-IMA-files.patch

$ mkdir -p ubuntu/.bzr-builddeb

$ echo "[BUILDDEB]\nmerge = True\nignore-unknowns = True" > ubuntu/.bzr-builddeb/default.conf

$ cd ubuntu
$ tar xvf ../vlc_2.2.3-2.debian.tar.xz
debian/
debian/patches/
debian/patches/fix-translation.patch

(...etc...)

$ bzr add
adding .bzr-builddeb
adding debian
adding .bzr-builddeb/default.conf
adding debian/NEWS

(...etc...)

$ debcommit -r
bzr commit -m 'releasing package vlc version 2.2.3-2'

(...etc...)

$ bzr bd
Building using working tree
Building package in merge mode
Looking for a way to retrieve the upstream tarball
Using the upstream tarball that is present in /home/jeremy/devel/other/vlc
bzr: ERROR: exceptions.ValueError: orig tarball file vlc_2.2.3.orig.tar.xz.asc has unknown extension

Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/bzrlib/commands.py", line 930, in exception_to_return_code
    return the_callable(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/bzrlib/commands.py", line 1121, in run_bzr
    ret = run(*run_argv)
  File "/usr/lib/python2.7/dist-packages/bzrlib/commands.py", line 673, in run_argv_aliases
    return self.run(**all_cmd_args)
  File "/usr/lib/python2.7/dist-packages/bzrlib/commands.py", line 697, in run
    return self._operation.run_simple(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/bzrlib/cleanup.py", line 136, in run_simple
    self.cleanups, self.func, *args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/bzrlib/cleanup.py", line 166, in _do_with_cleanups
    result = func(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/bzrlib/plugins/builddeb/cmds.py", line 449, in run
    builder.export()
  File "/usr/lib/python2.7/dist-packages/bzrlib/plugins/builddeb/builder.py", line 77, in export
    self.distiller.distill(self.target_dir)
  File "/usr/lib/python2.7/dist-packages/bzrlib/plugins/builddeb/source_distiller.py", line 79, in distill
    self._distill(target)
  File "/usr/lib/python2.7/dist-packages/bzrlib/plugins/builddeb/source_distiller.py", line 120, in _distill
    tarballs = self.upstream_provider.provide(parent_dir)
  File "/usr/lib/python2.7/dist-packages/bzrlib/plugins/builddeb/upstream/__init__.py", line 476, in provide
    for p in paths]
  File "/usr/lib/python2.7/dist-packages/bzrlib/plugins/builddeb/util.py", line 752, in component_from_orig_tarball
    "orig tarball file %s has unknown extension" % tarball_filename)
ValueError: orig tarball file vlc_2.2.3.orig.tar.xz.asc has unknown extension

bzr 2.7.0 on python 2.7.11 (Linux-4.4.0-23-generic-x86_64-with-
    Ubuntu-16.10-yakkety)
arguments: ['/usr/bin/bzr', 'bd']
plugins: bash_completion[2.7.0], builddeb[2.8.6], changelog_merge[2.7.0],
    grep[2.7.0], launchpad[2.7.0], netrc_credential_store[2.7.0],
    news_merge[2.7.0], po_merge[2.7.0], weave_fmt[2.7.0]
encoding: 'utf-8', fsenc: 'UTF-8', lang: 'en_US.UTF-8'

*** Bazaar has encountered an internal error. This probably indicates a
    bug in Bazaar. You can help us fix it by filing a bug report at
        https://bugs.launchpad.net/bzr/+filebug
    including this traceback and a description of the problem.

ProblemType: Bug
DistroRelease: Ubuntu 16.10
Package: bzr-builddeb 2.8.9
ProcVersionSignature: Ubuntu 4.4.0-23.41-generic 4.4.10
Uname: Linux 4.4.0-23-generic x86_64
ApportVersion: 2.20.1-0ubuntu4
Architecture: amd64
CurrentDesktop: GNOME
Date: Tue May 31 17:50:21 2016
EcryptfsInUse: Yes
InstallationDate: Installed on 2016-04-09 (51 days ago)
InstallationMedia: Ubuntu-GNOME 16.04 LTS "Xenial Xerus" - Beta amd64 (20160408)
PackageArchitecture: all
SourcePackage: bzr-builddeb
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Jeremy Bícha (jbicha) wrote :
Revision history for this message
Jeremy Bícha (jbicha) wrote :

I'm closing this bug since things are magically working today. I don't really understand what changed.

When I run dget http://httpredir.debian.org/debian/pool/main/v/vlc/vlc_2.2.3-2.dsc
it does not download the .orig.tar.xz.asc any more.

bzr bd works fine even if that .orig.tar.xz.asc is in the directory.

bzr was updated today but it was such a minor change it shouldn't have mattered unless rebuilding against yakkety changed something:
https://launchpadlibrarian.net/263920045/bzr_2.7.0-6_2.7.0-7.diff.gz

But that doesn't explain why dget is different (neither devscripts nor dpkg have been updated in Ubuntu recently).

Changed in bzr-builddeb (Ubuntu):
status: New → Fix Released
Revision history for this message
Jeremy Bícha (jbicha) wrote :

Never mind, vlc was updated in Debian and the new vlc dsc does not include the .asc.

But I can still reproduce this bug with say...

http://httpredir.debian.org/debian/pool/main/l/limnoria/limnoria_2016.05.06-2.dsc

Changed in bzr-builddeb (Ubuntu):
status: Fix Released → New
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in bzr-builddeb (Ubuntu):
status: New → Confirmed
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.