Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Working on Manjaro 18.1.5, Xfce stable, 4.19.96-1 kernel, with Python 3.8 #16

Open
Armag67 opened this issue Jan 21, 2020 · 0 comments
Open

Comments

@Armag67
Copy link

Armag67 commented Jan 21, 2020

Hello,

Due to a switching from amperes to watts for power supply in the latest kernels updates, I had to slightly modify cpug.py and investigator.py to make this application work properly on my Manjaro (18.1.5, Xfce stable, kernel 4.19.96-1, Pyhon 3.8.1) box with french locale and displaying now Xorg version, accurate distro logo, battery charges: now, full, full design and power now with the good units (Wh & W).

There is also a subtle bug in the sysdevcpu function in investigator.py. This bug only occur if /proc/cpuinfo and /sys/devices/system/cpu/ don't return the same number of cores. Then sysdevcpu function try to print:

            print("Error: Cannot decide if the cores are %s or %s.\n" +
                  "Using the lowest value as the real cores number." %
                  (self.cpuinfo('coresnum'), coresinsysdev))

which is buggy and should be replaced by:

            print("Error: Cannot decide if the cores are %s or %s.\n"
                  % (self.cpuinfo('coresnum'), coresinsysdev) +
                  "Using the lowest value as the real cores number.")

I suggest that the python-distro module must be added to the dependencies in order to use all my suggested modifications in the two diff files (in the attached tar.gz part) which covers the different modifications that I think are necessary.

diff_cpug_investigator-1414aad.tar.gz

Thanks to take a look.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant