aristocratos / bpytop

Linux/OSX/FreeBSD resource monitor
Apache License 2.0
10.19k stars 399 forks source link

[BUG] cannot use left and right arrows on Mac #401

Open Stooovie opened 1 year ago

Stooovie commented 1 year ago

Describe the bug

I can not use the left and right arrows to change options in MacOS (Ventura 13.4)

To Reproduce

1) run on MacOS Ventura 2) go to Options (esc) 3) try to change, say, theme

Expected behavior

options change with left and right arrow

Screenshots

[If applicable, add screenshots to help explain your problem.]

Info (please complete the following information): bpytop version: 1.0.68 psutil version: 5.9.3 MacOS terminal Python 3.11.4

Additional context

contents of ~/.config/bpytop/error.log

16/06/23 (14:13:16) | ERROR: Exception while getting cpu frequency!
16/06/23 (14:13:16) | ERROR: [Errno 2] No such file or directory (originated from sysctl(HW_CPU_FREQ))
Traceback (most recent call last):
  File "/opt/homebrew/bin/bpytop", line 3080, in _collect
    if CONFIG.show_cpu_freq and hasattr(psutil.cpu_freq(), "current"):
                                        ^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/bpytop/1.0.68/libexec/lib/python3.11/site-packages/psutil/__init__.py", line 1864, in cpu_freq
    ret = _psplatform.cpu_freq()
          ^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/bpytop/1.0.68/libexec/lib/python3.11/site-packages/psutil/_psosx.py", line 179, in cpu_freq
    curr, min_, max_ = cext.cpu_freq()
                       ^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory (originated from sysctl(HW_CPU_FREQ))
16/06/23 (14:15:15) | ERROR: Exception while getting cpu frequency!
16/06/23 (14:15:15) | ERROR: [Errno 2] No such file or directory (originated from sysctl(HW_CPU_FREQ))
Traceback (most recent call last):
  File "/opt/homebrew/bin/bpytop", line 3080, in _collect
    if CONFIG.show_cpu_freq and hasattr(psutil.cpu_freq(), "current"):
                                        ^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/bpytop/1.0.68/libexec/lib/python3.11/site-packages/psutil/__init__.py", line 1864, in cpu_freq
    ret = _psplatform.cpu_freq()
          ^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/bpytop/1.0.68/libexec/lib/python3.11/site-packages/psutil/_psosx.py", line 179, in cpu_freq
    curr, min_, max_ = cext.cpu_freq()
                       ^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory (originated from sysctl(HW_CPU_FREQ))
scottwmaxwell commented 11 months ago

It also seems that the enter key doesn't work.

I notice this when I press ESC for options and try use Enter to go to the Options.

ryandesign commented 9 months ago

The cpu_freq errors look like #404, allegedly solved by #405. The Enter key problem is #410, allegedly solved by #413.