vagnum08 / cpupower-gui

cpupower-gui is a graphical program that is used to change the scaling frequency limits of the cpu, similar to cpupower.
GNU General Public License v3.0
476 stars 31 forks source link

"int-expected, float-passed" error for the --min frequency #115

Open feg2hi opened 10 months ago

feg2hi commented 10 months ago

Describe the bug passing this command on the CLI throwth "int-expected, float-passed" error: /usr/bin/cpupower-gui frequency --min 800 --max 1700 0-7

To Reproduce Steps to reproduce the behaviour:

  1. Open terminal
  2. /usr/bin/cpupower-gui frequency --min 800 --max 1700 0-7
  3. See error

Expected behaviour No error

Setup (please complete the following information):

Additional context Fortunately, I could repair it for my use case. In the file /usr/share/cpupower-gui/cpupower_gui/helper.py I added two lines for explicit type conversion:

def set_cpu_min_freq(cpu, freq):
    """Set minimum frequency for CPU
...
    freq *= 1e3
    freq = int(freq) """ <<<< Add this line here

def set_cpu_max_freq(cpu, freq):
    """Set maximum frequency for CPU
...
    freq *= 1e3
    freq = int(freq) """ <<<< Add this line here

Would be fine to find the latest release in the repository for Ubuntu / Debian