apport autopkgtest regression due to kernel packaging changes

Bug #1766740 reported by Steve Langasek
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
apport (Ubuntu)
Fix Released
High
Brian Murray
Xenial
Fix Released
Undecided
Unassigned
Bionic
Fix Released
High
Brian Murray

Bug Description

[SRU Justification]
In bionic, linux-image-$kvers-$flavor is now built from the linux-signed source package on amd64, not from the linux source package. This now causes a test to fail in the apport test suite:

[...]
======================================================================
FAIL: test_run_crash_kernel (__main__.T)
run_crash() for a kernel error
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./test_ui.py", line 1305, in test_run_crash_kernel
    self.assertEqual(self.ui.opened_url, 'http://linux.bugs.example.com/%i' % se
lf.ui.crashdb.latest_id())
AssertionError: 'http://linux-signed.bugs.example.com/5' != 'http://linux.bugs.e
xample.com/5'
- http://linux-signed.bugs.example.com/5
? -------
+ http://linux.bugs.example.com/5

----------------------------------------------------------------------
Ran 70 tests in 79.815s

FAILED (failures=1)
[...]

(https://objectstorage.prodstack4-5.canonical.com/v1/AUTH_77e2ada1e7a84929a74ba3b87153c0ac/autopkgtest-bionic/bionic/amd64/a/apport/20180424_222219_45dc8@/log.gz)

This test needs to be fixed to know about the packaging change.

Note that this packaging change is expected to soon be SRUed back to all Ubuntu releases, so apport's testsuite change should also be SRUed.

[Test case]
This passes if the autopkgtests pass.

[Regression potential]
The test could be changed to pass while leaving underlying issues in the code. This has probably not happened here.

Steve Langasek (vorlon)
Changed in apport (Ubuntu):
importance: Undecided → High
status: New → Triaged
description: updated
tags: added: id-5adfb5d8feb97ed68bb8be28
tags: added: id-5ae35ea55ac10e9203cade8d
Changed in apport (Ubuntu):
status: Triaged → In Progress
assignee: nobody → Brian Murray (brian-murray)
Revision history for this message
Brian Murray (brian-murray) wrote :

If the source package has changed then there will also need to be an additional apport package hook, symlink, for source_linux-signed.py otherwise bug reports about kernels are going to be pretty incomplete.

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

This bug was fixed in the package apport - 2.20.10-0ubuntu1

---------------
apport (2.20.10-0ubuntu1) cosmic; urgency=medium

  * New upstream release:
    - backends/packaging-apt-dpkg.py: when using a permanent sandbox better
      check for the package being already available thereby reducing quantity
      of downloads.
    - apport/report.py: Use timeout parameter in subprocess to limit how long
      we'll wait for gdb to return information as gdb can hang with some core
      files.
    - data/apport: Fix PEP8 issues
    - apport/ui.py: Include ProblemType in reports which are updated as
      package hooks may expect the report to have a ProblemType. (LP: #1766794)
    - test/test_ui.py: modify run_crash_kernel test to account for the fact
      that linux-image-$kvers-$flavor is now built from the linux-signed
      source package on amd64 and ppc64el. (LP: #1766740)
  * data/general-hooks/ubuntu.py: Fix UnicodeDecodeError when processing
    DpkgTerminalLog. (LP: #1766337)
  * data/general-hooks/ubuntu.py: Don't display a messy error if python or
    python3 is not installed. (LP: #1769262)
  * debian/apport.links: source_linux-signed.py -> source_linux.py package
    hook (LP: #1766740)
  * data/package-hooks/source_linux.py: Redirect bugs filed about the
    linux-signed source package to linux. (LP: #1766740)

 -- Brian Murray <email address hidden> Thu, 10 May 2018 09:31:34 -0700

Changed in apport (Ubuntu):
status: In Progress → Fix Released
Changed in apport (Ubuntu Bionic):
status: New → In Progress
assignee: nobody → Brian Murray (brian-murray)
importance: Undecided → High
Steve Langasek (vorlon)
description: updated
Revision history for this message
Steve Langasek (vorlon) wrote : Please test proposed package

Hello Steve, or anyone else affected,

Accepted apport into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/apport/2.20.9-0ubuntu7.2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in apport (Ubuntu Bionic):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-bionic
Revision history for this message
Brian Murray (brian-murray) wrote :
tags: added: verification-done verification-done-bionic
removed: verification-needed verification-needed-bionic
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package apport - 2.20.9-0ubuntu7.2

---------------
apport (2.20.9-0ubuntu7.2) bionic; urgency=medium

  * apport/ui.py: Include ProblemType in reports which are updated as
    package hooks may expect the report to have a ProblemType. (LP: #1766794)
  * test/test_ui.py: modify run_crash_kernel test to account for the fact
    that linux-image-$kvers-$flavor is now built from the linux-signed
    source package on amd64 and ppc64el. (LP: #1766740)
  * data/general-hooks/ubuntu.py: Don't display a messy error if python or
    python3 is not installed. (LP: #1769262)
  * debian/apport.links: source_linux-signed.py -> source_linux.py package
    hook (LP: #1773012)
  * data/package-hooks/source_linux.py: Redirect bugs filed about the
    linux-signed source package to linux. (LP: #1773012)

 -- Brian Murray <email address hidden> Wed, 30 May 2018 15:19:49 -0700

Changed in apport (Ubuntu Bionic):
status: Fix Committed → Fix Released
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Update Released

The verification of the Stable Release Update for apport has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Changed in apport (Ubuntu Xenial):
status: New → Triaged
Revision history for this message
Robie Basak (racb) wrote :

This got trumped by security, so I rebased it and bumped the version for you - attached. I then reviewed it, but given the clarified SRU policy on test changes, does this still qualify?

From https://wiki.ubuntu.com/StableReleaseUpdates#When_not_to_upload:

"Do not upload SRUs for bugs which do not affect users at runtime."

Does this affect users at runtime, and if not, is there some other reason that we want this uploaded now, rather than bundling it with some other useful changes? I note that the previous Bionic SRU for the same issue did have other bundled changes.

Revision history for this message
Robie Basak (racb) wrote :

This got trumped by security, so I rebased it and bumped the version for you - attached. I then reviewed it, but given the clarified SRU policy on test changes, does this still qualify?

From https://wiki.ubuntu.com/StableReleaseUpdates#When_not_to_upload:

"Do not upload SRUs for bugs which do not affect users at runtime."

Does this affect users at runtime, and if not, is there some other reason that we want this uploaded now, rather than bundling it with some other useful changes? I note that the previous Bionic SRU for the same issue did have other bundled changes.

Revision history for this message
Robie Basak (racb) wrote : Proposed package upload rejected

An upload of apport to xenial-proposed has been rejected from the upload queue for the following reason: "Trumped by a security update so needs updating, but also see https://bugs.launchpad.net/ubuntu/+source/apport/+bug/1766740/comments/8".

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

This bug was fixed in the package apport - 2.20.1-0ubuntu2.22

---------------
apport (2.20.1-0ubuntu2.22) xenial-security; urgency=medium

  [ Michael Hudson-Doyle ]
  * SECURITY REGRESSION: fix autopkgtest failures since recent security
    update (LP: #1854237)
    - Fix regression in creating report for crashing setuid process by getting
      kernel to tell us the executable path rather than reading
      /proc/[pid]/exe.
    - Fix deletion of partially written core files.
    - Fix test_get_logind_session to use new API.
    - Restore add_proc_info raising ValueError for a dead process.
    - Delete test_lock_symlink, no longer applicable now that the lock is
      created in a directory only root can write to.

  [ Tiago Stürmer Daitx ]
  * SECURITY REGRESSION: 'module' object has no attribute 'O_PATH'
    (LP: #1851806)
    - apport/report.py, apport/ui.py: use file descriptors for /proc/pid
      directory access only when running under python 3; prevent reading /proc
      maps under python 2 as it does not provide a secure way to do so; use
      io.open for better compatibility between python 2 and 3.
  * data/apport: fix number of arguments passed through socks into a container.
  * test/test_report.py: test login session with both pid and proc_pid_fd.
  * test/test_apport_valgrind.py: skip test_sandbox_cache_options if system
    has little memory.
  * test/test_ui.py: modify run_crash_kernel test to account for the fact that
    linux-image-$kvers-$flavor is now built from the linux-signed source
    package on amd64 and ppc64el. (LP: #1766740)

 -- Tiago Stürmer Daitx <email address hidden> Thu, 27 Feb 2020 03:18:45 +0000

Changed in apport (Ubuntu Xenial):
status: Triaged → 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.