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

TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType' #226

Closed
BluishHumility opened this issue Jan 13, 2025 · 1 comment

Comments

@BluishHumility
Copy link

Step 1: Describe your environment

  • System (Intel/AMD/Raspberry Pi etc): Intel NUC 11 Extreme - NUC11BTMi7 v: M26264-403
  • OS version: Arch Linux, 6.12.8 Zen kernel, Sway WM
  • s-tui version: 1.1.6
  • Installation method(pip/PPA/source code): sudo pacman -S s-tui

Step 2: Describe the problem:

Observed Results:

I installed the application from the Arch repo and attempted to run it, but it crashes like this:

❯ s-tui
Traceback (most recent call last):
 File "/usr/bin/s-tui", line 8, in <module>
   sys.exit(main())
            ~~~~^^
 File "/usr/lib/python3.13/site-packages/s_tui/s_tui.py", line 958, in main
   graph_controller = GraphController(args)
 File "/usr/lib/python3.13/site-packages/s_tui/s_tui.py", line 758, in __init__
   possible_sources = self._load_config(args.t_thresh)
 File "/usr/lib/python3.13/site-packages/s_tui/s_tui.py", line 691, in _load_config
   FanSource(),
   ~~~~~~~~~^^
 File "/usr/lib/python3.13/site-packages/s_tui/sources/fan_source.py", line 48, in __init__
   sensors_dict = psutil.sensors_fans()
 File "/usr/lib/python3.13/site-packages/psutil/__init__.py", line 2326, in sensors_fans
   return _psplatform.sensors_fans()
          ~~~~~~~~~~~~~~~~~~~~~~~~^^
 File "/usr/lib/python3.13/site-packages/psutil/_pslinux.py", line 1514, in sensors_fans
   current = int(bcat(base + '_input'))
TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType'

Debug Results, output of s-tui -d created in a file _s-tui.log:

2025-01-12 22:31:33,671 [_load_config()] [DEBUG]  Config file not found
2025-01-12 22:31:33,671 [_load_config()] [DEBUG]  No refresh rate configured
2025-01-12 22:31:33,671 [_load_config()] [DEBUG]  No user config for utf8
2025-01-12 22:31:33,671 [_load_config()] [DEBUG]  No user config for temp threshold
2025-01-12 22:31:33,890 [__init__()] [DEBUG]  Temp sensor name Acpitz,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name PackageId0,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Core0,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Core1,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Core2,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Core3,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Core4,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Core5,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Core6,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Core7,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Iwlwifi_1,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Composite,0
2025-01-12 22:31:33,891 [__init__()] [DEBUG]  Temp sensor name Composite,1
2025-01-12 22:31:33,896 [read_power()] [WARNI]  ignoring (PermissionError(13, 'Permission denied'), '/sys/class/powercap/intel-rapl:0/') for file <class 'RuntimeWarning'>
2025-01-12 22:31:33,896 [read_power()] [WARNI]  ignoring (PermissionError(13, 'Permission denied'), '/sys/class/powercap/intel-rapl:0:0/') for file <class 'RuntimeWarning'>
2025-01-12 22:31:33,896 [read_power()] [WARNI]  ignoring (PermissionError(13, 'Permission denied'), '/sys/class/powercap/intel-rapl:0:1/') for file <class 'RuntimeWarning'>
2025-01-12 22:31:33,896 [read_power()] [WARNI]  ignoring (PermissionError(13, 'Permission denied'), '/sys/class/powercap/intel-rapl:1/') for file <class 'RuntimeWarning'>

Step 3: Reproduce the problem:

Steps to reproduce:

  1. sudo pacman -S s-tui
  2. s-tui

Thanks for taking a look, please let me know if there is anything I can do to help.

@BluishHumility
Copy link
Author

My apologies for not performing adequate troubleshooting before opening the issue; after an ordinary reboot, the application now opens normally.

image

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