/usr/bin/indicator-cpufreq:ImportError:load_module:get_introspection_module:__init__:/usr/bin/indicator-cpufreq@77:/usr/lib/python3/dist-packages/indicator_cpufreq/indicator.py@21:load_module

Bug #1971206 reported by errors.ubuntu.com bug bridge
46
This bug affects 9 people
Affects Status Importance Assigned to Milestone
indicator-cpufreq
New
Undecided
Unassigned
indicator-cpufreq (Ubuntu)
Fix Released
High
Brian Murray

Bug Description

The Ubuntu Error Tracker has been receiving reports about a problem regarding indicator-cpufreq. This problem was most recently seen with package version 0.2.4-4, the problem page at https://errors.ubuntu.com/problem/e6bab31df66eac44e59fed969b74f68ea3b35360 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/.

Revision history for this message
Brian Murray (brian-murray) wrote :

Here's the traceback:

Traceback (most recent call last):
  File "/usr/bin/indicator-cpufreq", line 77, in <module>
    from indicator_cpufreq.indicator import MyIndicator
  File "/usr/lib/python3/dist-packages/indicator_cpufreq/indicator.py", line 21, in <module>
    from gi.repository import AppIndicator3 as appindicator
  File "/usr/lib/python3/dist-packages/gi/importer.py", line 144, in load_module
    raise ImportError(e)
ImportError: Requiring namespace 'Gtk' version '3.0', but '4.0' is already loaded

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

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

Changed in indicator-cpufreq (Ubuntu):
status: New → Confirmed
fprietog (fprietog)
tags: added: kinetic
Revision history for this message
fprietog (fprietog) wrote :

Problem also happens in kinetic.

Quick fix:
Edit "/usr/bin/indicator-cpufreq" file to insert this three lines...

import gi
gi.require_version("Gtk", "3.0")
from gi.repository import Gtk

... just before this line:

# Add project root directory (enable symlink, and trunk execution).

Anti Mailer (antimailer)
tags: added: xenial
Revision history for this message
Anti Mailer (antimailer) wrote :

Since there seems no maintaining a long time maybe also interesting:
https://github.com/xuancong84/indicator-cpufreq

Changed in indicator-cpufreq (Ubuntu):
assignee: nobody → Brian Murray (brian-murray)
status: Confirmed → In Progress
importance: Undecided → High
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package indicator-cpufreq - 0.2.2-0ubuntu4

---------------
indicator-cpufreq (0.2.2-0ubuntu4) mantic; urgency=medium

  * Resolve an ImportError crash when importing Gtk. (LP: #1971206)

 -- Brian Murray <email address hidden> Wed, 21 Jun 2023 13:26:33 -0700

Changed in indicator-cpufreq (Ubuntu):
status: In Progress → 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.