Test depends cannot be multiline and are silently ignored if so

Bug #1073856 reported by Scott Ritchie
28
This bug affects 3 people
Affects Status Importance Assigned to Milestone
autopkgtest (Debian)
Fix Released
Unknown
autopkgtest (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

If I define a test like this:

Tests: foo
Depends: @, libfoo,
  libbar

then autopackage test will prepare this test without libbar and without giving any sort of malformed warning.

This seems really wrong, as debian/control files normally support this sort of multiline listing of dependencies

Tags: patch
Revision history for this message
Launchpad Janitor (janitor) wrote :

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

Changed in autopkgtest (Ubuntu):
status: New → Confirmed
Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

Thanks for your report.

Changed in autopkgtest (Ubuntu):
importance: Undecided → High
status: Confirmed → Triaged
Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

this is the faulty regex in runner/adt-run

1233: initre = regexp.compile('([A-Z][-0-9a-zA-Z]*)\s*\:\s*(.*)$')

Changed in autopkgtest (Ubuntu):
importance: High → Medium
Revision history for this message
Julian Taylor (jtaylor) wrote :

why use a regex at all, this is what I use in my own (awful) adtrunner
depends = depends.replace("(", " ").replace("[", " ")
packages = [x.split()[0] for x in depends.split(",")]

depends is a string from debian.deb822

Changed in autopkgtest (Debian):
status: Unknown → New
Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

Here is a proposition of patch.
Note that multiline parsing in control files is currently completely broken, and fixing it changes the way numbering is done in the list 'stanzas' which might have side-effects in other parts of adt-run. But overall I think it is safe.

Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

same fix with a packaging fix. Also adding a dependency on python-debian breaks the principle of using on minimal system, but it is already installed in the test environment as a dependency of update-notifier-common, so I think it is acceptable.

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "autopkgtest_2.2.3ubuntu2.debdiff" of this bug report has been identified as being a patch in the form of a debdiff. The ubuntu-sponsors team has been subscribed to the bug report so that they can review and hopefully sponsor the debdiff. In the event that this is in fact not a patch you can resolve this situation by removing the tag 'patch' from the bug report and editing the attachment so that it is not flagged as a patch. Additionally, if you are member of the ubuntu-sponsors team please also unsubscribe the team from this bug report.

[This is an automated message performed by a Launchpad user owned by Brian Murray. Please contact him regarding any issues with the action taken in this bug report.]

tags: added: patch
Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

Previous patch was broken (wrong variable name and broken indentation)
This one was tested against tabix, pygobject and glib

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package autopkgtest - 2.2.3ubuntu2

---------------
autopkgtest (2.2.3ubuntu2) raring; urgency=low

  * Use debian.deb822 to parse control files. (LP: #1073856)
 -- Jean-Baptiste Lallement <email address hidden> Wed, 12 Dec 2012 22:48:51 +0100

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

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.