[Bug 1999156] Re: /usr/share/apport/whoopsie-upload-all:FileNotFoundError:/usr/share/apport/whoopsie-upload-all at 220:main:collect_info:process_report:add_package_info:add_package:get_version:_apt_pkg:_cache:__init__:_check_and_create_required_dirs:makedirs:makedirs

Benjamin Drung 1999156 at bugs.launchpad.net
Thu Dec 8 15:32:05 UTC 2022


** Description changed:

+ ```
+ Traceback (most recent call last):
+   File "/usr/share/apport/whoopsie-upload-all", line 220, in <module>
+     main()
+   File "/usr/share/apport/whoopsie-upload-all", line 202, in main
+     stamps = collect_info()
+   File "/usr/share/apport/whoopsie-upload-all", line 150, in collect_info
+     res = process_report(r)
+   File "/usr/share/apport/whoopsie-upload-all", line 90, in process_report
+     r.add_package_info()
+   File "/usr/lib/python3/dist-packages/apport/report.py", line 351, in add_package_info
+     version = self.add_package(package)
+   File "/usr/lib/python3/dist-packages/apport/report.py", line 320, in add_package
+     version = packaging.get_version(package)
+   File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 163, in get_version
+     pkg = self._apt_pkg(package)
+   File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 156, in _apt_pkg
+     return self._cache()[package]
+   File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 121, in _cache
+     self._apt_cache = apt.Cache(progress, rootdir='/')
+   File "/usr/lib/python3/dist-packages/apt/cache.py", line 143, in __init__
+     self._check_and_create_required_dirs(rootdir)
+   File "/usr/lib/python3/dist-packages/apt/cache.py", line 183, in _check_and_create_required_dirs
+     os.makedirs(rootdir + d)
+   File "/usr/lib/python3.10/os.py", line 215, in makedirs
+     makedirs(head, exist_ok=exist_ok)
+   File "/usr/lib/python3.10/os.py", line 225, in makedirs
+     mkdir(name, mode)
+ FileNotFoundError: [Errno 2] No such file or directory: '//var/cache/apt/archives'
+ ```
+ 
  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.2, the problem page at https://errors.ubuntu.com/problem/e3a000aa8a314f9ae9303dcd52a119799a00496f 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/.

-- 
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/1999156

Title:
  /usr/share/apport/whoopsie-upload-
  all:FileNotFoundError:/usr/share/apport/whoopsie-upload-
  all at 220:main:collect_info:process_report:add_package_info:add_package:get_version:_apt_pkg:_cache:__init__:_check_and_create_required_dirs:makedirs:makedirs

Status in apport package in Ubuntu:
  New

Bug description:
  ```
  Traceback (most recent call last):
    File "/usr/share/apport/whoopsie-upload-all", line 220, in <module>
      main()
    File "/usr/share/apport/whoopsie-upload-all", line 202, in main
      stamps = collect_info()
    File "/usr/share/apport/whoopsie-upload-all", line 150, in collect_info
      res = process_report(r)
    File "/usr/share/apport/whoopsie-upload-all", line 90, in process_report
      r.add_package_info()
    File "/usr/lib/python3/dist-packages/apport/report.py", line 351, in add_package_info
      version = self.add_package(package)
    File "/usr/lib/python3/dist-packages/apport/report.py", line 320, in add_package
      version = packaging.get_version(package)
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 163, in get_version
      pkg = self._apt_pkg(package)
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 156, in _apt_pkg
      return self._cache()[package]
    File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 121, in _cache
      self._apt_cache = apt.Cache(progress, rootdir='/')
    File "/usr/lib/python3/dist-packages/apt/cache.py", line 143, in __init__
      self._check_and_create_required_dirs(rootdir)
    File "/usr/lib/python3/dist-packages/apt/cache.py", line 183, in _check_and_create_required_dirs
      os.makedirs(rootdir + d)
    File "/usr/lib/python3.10/os.py", line 215, in makedirs
      makedirs(head, exist_ok=exist_ok)
    File "/usr/lib/python3.10/os.py", line 225, in makedirs
      mkdir(name, mode)
  FileNotFoundError: [Errno 2] No such file or directory: '//var/cache/apt/archives'
  ```

  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.2, the problem page at https://errors.ubuntu.com/problem/e3a000aa8a314f9ae9303dcd52a119799a00496f 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/.

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




More information about the foundations-bugs mailing list