[Bug 1979211] Re: /usr/share/apport/apport:AttributeError:/usr/share/apport/apport at 531:parse_arguments:print_usage:_print_message

Launchpad Bug Tracker 1979211 at bugs.launchpad.net
Mon Jun 27 14:31:06 UTC 2022


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

---------------
apport (2.22.0-0ubuntu1) kinetic; urgency=medium

  * New upstream release:
    - Replace `ProblemReport.get_date` by `ProblemReport.get_timestamp`, fixes
      regression in 2.21.0 (LP: #1978487)
    - apport-gtk: Exclude trailing dot from URL links (LP: #1978301)
    - Fix `AttributeError`: 'NoneType' object has no attribute 'write', fixes
      regression in 2.21.0 (LP: #1979211)
    - apport_python_hook: Properly handle missing modules (LP: #1774843)
    - apport_python_hook: Fix FileNotFoundError if the current directory was
      deleted (LP: #1979637)
    - apport_python_hook: Fix crash if os.getcwd() fails (LP: #1977954)
    - Replace deprecated 'imp' module (LP: #1947425)
    - whoopsie-upload-all: Fix 'EOFError' object has no attribute 'errno',
      fixes regression in 2.21.0 (LP: #1979681)
  * Fix KeyError: 'CasperMD5json'

 -- Benjamin Drung <bdrung at ubuntu.com>  Mon, 27 Jun 2022 12:03:00 +0200

** Changed in: apport (Ubuntu)
       Status: Triaged => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to apport in Ubuntu.
https://bugs.launchpad.net/bugs/1979211

Title:
  /usr/share/apport/apport:AttributeError:/usr/share/apport/apport at 531:parse_arguments:print_usage:_print_message

Status in Apport:
  Fix Released
Status in apport package in Ubuntu:
  Fix Released
Status in apport source package in Focal:
  New
Status in apport source package in Impish:
  New
Status in apport source package in Jammy:
  New

Bug description:
  The Ubuntu Error Tracker has been receiving reports about a problem regarding apport.  This problem was most recently seen with package version 2.20.11-0ubuntu82.1, the problem page at https://errors.ubuntu.com/problem/e714f8181c0785693f3a66969c594a3b19bcab2b contains more details, including versions of packages affected, stacktrace or traceback, and individual crash reports.
  If you do not have access to the Ubuntu Error Tracker and are a software developer, you can request it at http://forms.canonical.com/reports/.

  Traceback (most recent call last):
    File "/usr/share/apport/apport", line 531, in <module>
      options = parse_arguments()
    File "/usr/share/apport/apport", line 463, in parse_arguments
      parser.print_usage()
    File "/usr/lib/python3.10/argparse.py", line 2562, in print_usage
      self._print_message(self.format_usage(), file)
    File "/usr/lib/python3.10/argparse.py", line 2573, in _print_message
      file.write(message)
  AttributeError: 'NoneType' object has no attribute 'write'

  This bug can be reproduced by configuring the previously supported
  parameters to Apport and then let a process crash (e.g. call divide-
  by-zero):

  ```
  echo "|/usr/share/apport/apport %p %s %c %d %P %E" | sudo tee /proc/sys/kernel/core_pattern
  ```

  So this bug is a regression of commit c320e910a516 ("Switch to using
  non-positional arguments") which is a fix for CVE-2022-28658 and
  CVE-2021-3899.

To manage notifications about this bug go to:
https://bugs.launchpad.net/apport/+bug/1979211/+subscriptions




More information about the foundations-bugs mailing list