Depends: @ only works when building the source

Bug #1015400 reported by Jean-Baptiste Lallement
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
autopkgtest (Debian)
Fix Released
Unknown
autopkgtest (Ubuntu)
Fix Released
High
Martin Pitt
Quantal
Fix Released
High
Martin Pitt
ubiquity (Ubuntu)
Fix Released
Undecided
Colin Watson
Quantal
Fix Released
Undecided
Colin Watson

Bug Description

Automated test https://jenkins.qa.ubuntu.com/view/Quantal/view/AutoPkg%20Test/job/quantal-adt-ubiquity/37/

autopkgtest fails with
Traceback (most recent call last):
  File "/tmp/tmp.zNrmcfNahV/dsc0-build/ubiquity-2.11.5/debian/tests/../../tests/run", line 138, in <module>
    suite = unittest.TestLoader().loadTestsFromNames(tests)
  File "/usr/lib/python3.2/unittest/loader.py", line 132, in loadTestsFromNames
    suites = [self.loadTestsFromName(name, module) for name in names]
  File "/usr/lib/python3.2/unittest/loader.py", line 132, in <listcomp>
    suites = [self.loadTestsFromName(name, module) for name in names]
  File "/usr/lib/python3.2/unittest/loader.py", line 91, in loadTestsFromName
    module = __import__('.'.join(parts_copy))
  File "/tmp/tmp.zNrmcfNahV/dsc0-build/ubiquity-2.11.5/tests/test_filteredcommand.py", line 6, in <module>
    import mock
ImportError: No module named mock

The test explicitly calls python3, in debian/tests/control "Depends" should be updated to use python3-mock instead of python-mock

ProblemType: Bug
DistroRelease: Ubuntu 12.10
Package: ubiquity (not installed)
ProcVersionSignature: Ubuntu 3.4.0-5.11-generic 3.4.0
Uname: Linux 3.4.0-5-generic x86_64
NonfreeKernelModules: fglrx
ApportVersion: 2.2.3-0ubuntu4
Architecture: amd64
Date: Wed Jun 20 07:19:59 2012
InstallCmdLine: file=/cdrom/preseed/ubuntu.seed vga=788 initrd=/install/initrd.gz quiet -- console-setup/layoutcode=fr console-setup/variantcode=oss
ProcEnviron:
 TERM=xterm
 PATH=(custom, user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: ubiquity
UpgradeStatus: Upgraded to quantal on 2012-01-31 (140 days ago)

Revision history for this message
Martin Pitt (pitti) wrote :

While ubiquity's d/t/control should certainly be updated, I believe there is a bug in autopkgtest. The control file does not specify "no-build-needed", so autopkgtest needs to build the package first, and hence install its build dependencies. The recent change of adding --no-built-binaries seems to have triggered this, but "do not install the built binaries" != "do not build binaries".

I'll look into this.

Changed in autopkgtest (Ubuntu Quantal):
assignee: nobody → Martin Pitt (pitti)
importance: Undecided → High
status: New → In Progress
Colin Watson (cjwatson)
Changed in ubiquity (Ubuntu Quantal):
assignee: nobody → Colin Watson (cjwatson)
status: New → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubiquity - 2.11.6

---------------
ubiquity (2.11.6) quantal; urgency=low

  [ Dmitrijs Ledkovs ]
  * Run debconf-updatepo to remove migration-assistant translations.

  [ Alan Bell ]
  * Adjust the default use_device_title label to make more sense when read
    by screen readers (LP: #1010179).

  [ Stéphane Graber ]
  * Port ubiquity-bluetooth-agent from the old python-gobject to the
    gi version of gobject as required with python3. (LP: #1013172)

  [ Matthew Paul Thomas ]
  * Improvements to the third-party software text:
    - Changes "display" to "play" (since MP3 is about audio, not video).
    - Adds mention of graphics drivers (because the installer may install a
      Nvidia proprietary driver).
    - Changes "wireless" to "wi-fi".
    - Changes "closed-source" to "proprietary", matching Ubuntu Software
      Center.
    - Removes repetition of "the software", by changing "the software's
      documentation" to "its documentation".

  [ Colin Watson ]
  * Add XS-Testsuite header, as per current DEP-8.
  * debian/tests/control: Depend on python3-mock rather than python-mock
    (LP: #1015400).
  * Automatic update of included source packages: apt-setup 1:0.56ubuntu2,
    partconf 1.38, partman-basicmethods 50, partman-jfs 36, partman-newworld
    27, partman-reiserfs 53, partman-xfs 50.

  [ Luke Yelavich ]
  * Show the a11y profile indicator in oem-config as well as in
    maybe-ubiquity mode.
  * bin/ubiquity-dm: Load at-spi for both OEM config and ubiquity.
 -- Colin Watson <email address hidden> Wed, 20 Jun 2012 09:37:32 +0100

Changed in ubiquity (Ubuntu Quantal):
status: Fix Committed → Fix Released
Martin Pitt (pitti)
summary: - update depends to python3-mock in autopkgtest control file
+ does not build packages which do not declare "no-build-needed"
Revision history for this message
Martin Pitt (pitti) wrote : Re: does not build packages which do not declare "no-build-needed"

To be investigated: Colin reported that adt-ubiquity does not actually seem to install the packages from "Depends: @". This might or might not be a separate bug.

Martin Pitt (pitti)
summary: - does not build packages which do not declare "no-build-needed"
+ Depends: @ only works when building the source
Revision history for this message
Martin Pitt (pitti) wrote :

> The control file does not specify "no-build-needed", so autopkgtest needs to build the package first

This was wrong. According to /usr/share/doc/autopkgtest/README.package-tests.gz it's the other way around: A control file needs to specify "build-needed" explicitly if it needs to be built for running the tests. So if Ubiquity's tests need a built tree, it would need to specify it.

The actual bug here is comment 4: adt-run does not expand "Depends: @" if the tree does not get built. With --no-built-binaries this does not happen. I'll report this as a bug in Debian and add some more details there.

Changed in autopkgtest (Debian):
status: Unknown → New
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package autopkgtest - 2.2.0ubuntu2

---------------
autopkgtest (2.2.0ubuntu2) quantal; urgency=low

  * runner/adt-run: Expand '@' test Depends: from the test package's
    debian/control instead from the list of built .debs. The latter does not
    work if we do not actually build the source. This uses dh_listpackage to
    avoid duplicating all the "Architecture:" parsing magic, so add a
    debhelper dependency. (LP: #1015400, Closes: #678359)
 -- Martin Pitt <email address hidden> Thu, 21 Jun 2012 10:51:00 +0200

Changed in autopkgtest (Ubuntu Quantal):
status: In Progress → Fix Released
Revision history for this message
Colin Watson (cjwatson) wrote : Re: [Bug 1015400] Re: Depends: @ only works when building the source

I don't think ubiquity's DEP-8 tests should need a built source tree.
They need the source tree, but it's fine (in fact preferable, for
isolation purposes) for it to be merely unpacked but not built.

Changed in autopkgtest (Debian):
status: New → Fix Released
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.