[Bug 2141637] Re: ImportError: cannot import name 'inhibit_sleep' from 'DistUpgrade.utils' during 25.10 to 26.04 upgrade

Chris Guiver 2141637 at bugs.launchpad.net
Thu Feb 12 08:48:33 UTC 2026


Thank you for taking the time to report this bug and helping to make
Ubuntu better. Please execute the following command only once, as it
will automatically gather debugging information, in a terminal:

  apport-collect 2141637

When reporting bugs in the future please use apport by using 'ubuntu-
bug' and the name of the package affected. You can learn more about this
functionality at https://help.ubuntu.com/community/ReportingBugs.

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

Title:
  ImportError: cannot import name 'inhibit_sleep' from
  'DistUpgrade.utils' during 25.10 to 26.04 upgrade

Status in ubuntu-release-upgrader package in Ubuntu:
  New

Bug description:
  While attempting an upgrade to the Ubuntu 26.04 "Resolute Raccoon"
  development branch using do-release-upgrade -d, the process fails
  immediately after downloading the upgrader tarball due to a Python
  ImportError.

  Steps to reproduce:

      Run sudo do-release-upgrade -d on an Ubuntu 25.10 system.
      The upgrader downloads the "resolute" tarball to /tmp.
      The process crashes before the UI initializes.

  Expected Behavior:
  The upgrader should initialize and begin the "Calculating Changes" phase.
  Actual Behavior:
  A Traceback occurs because DistUpgradeController.py attempts to import inhibit_sleep from DistUpgrade.utils, but that function is missing from the utils.py file in the current Resolute archive.

      Traceback (most recent call last):
    File "/tmp/ubuntu-release-upgrader-XXXXXX/resolute", line 8, in <module>
      sys.exit(main())
    File "/tmp/ubuntu-release-upgrader-XXXXXX/DistUpgrade/DistUpgradeMain.py", line 222, in main
      from .DistUpgradeController import DistUpgradeController
    File "/tmp/ubuntu-release-upgrader-XXXXXX/DistUpgrade/DistUpgradeController.py", line 43, in <module>
      from .utils import (..., inhibit_sleep)
  ImportError: cannot import name 'inhibit_sleep' from 'DistUpgrade.utils'

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-release-upgrader/+bug/2141637/+subscriptions




More information about the foundations-bugs mailing list