system_monitor crashes when -o/-i are not provided by he user.
Command : system_monitor system_monitor -p "systemd glusterfsd glusterd"
<When -o is missing> :
[root@gqas013 ~]# system_monitor system_monitor -p "systemd glusterfsd glusterd"
Traceback (most recent call last):
File "/usr/bin/system_monitor", line 9, in
load_entry_point('system-monitor==0.1', 'console_scripts', 'system_monitor')()
File "/usr/lib/python2.7/site-packages/system_monitor/system_monitor.py", line 281, in main
args.func(args)
File "/usr/lib/python2.7/site-packages/system_monitor/system_monitor.py", line 131, in system_monitor
if os.path.exists(filename):
File "/usr/lib64/python2.7/genericpath.py", line 18, in exists
os.stat(path)
TypeError: coercing to Unicode: need string or buffer, NoneType found
[root@gqas013 ~]#
<When -i is missing> :
Command : system_monitor system_monitor -p "systemd glusterfsd glusterd" -o "/tmp/node_1.xlsx"
Waiting for None seconds to take samples
Traceback (most recent call last):
File "/usr/bin/system_monitor", line 9, in
load_entry_point('system-monitor==0.1', 'console_scripts', 'system_monitor')()
File "/usr/lib/python2.7/site-packages/system_monitor/system_monitor.py", line 281, in main
args.func(args)
File "/usr/lib/python2.7/site-packages/system_monitor/system_monitor.py", line 149, in system_monitor
time.sleep(int(interval))
TypeError: int() argument must be a string or a number, not 'NoneType'
[root@gqas013 ~]#
[root@gqas013 ~]#
The help menu says that both of them default to None,so IMHO it's be nice to handle :)
system_monitor crashes when -o/-i are not provided by he user.
Command : system_monitor system_monitor -p "systemd glusterfsd glusterd"
<When -o is missing> :
[root@gqas013 ~]# system_monitor system_monitor -p "systemd glusterfsd glusterd"
Traceback (most recent call last):
File "/usr/bin/system_monitor", line 9, in
load_entry_point('system-monitor==0.1', 'console_scripts', 'system_monitor')()
File "/usr/lib/python2.7/site-packages/system_monitor/system_monitor.py", line 281, in main
args.func(args)
File "/usr/lib/python2.7/site-packages/system_monitor/system_monitor.py", line 131, in system_monitor
if os.path.exists(filename):
File "/usr/lib64/python2.7/genericpath.py", line 18, in exists
os.stat(path)
TypeError: coercing to Unicode: need string or buffer, NoneType found
[root@gqas013 ~]#
<When -i is missing> :
Command : system_monitor system_monitor -p "systemd glusterfsd glusterd" -o "/tmp/node_1.xlsx"
Waiting for None seconds to take samples
Traceback (most recent call last):
File "/usr/bin/system_monitor", line 9, in
load_entry_point('system-monitor==0.1', 'console_scripts', 'system_monitor')()
File "/usr/lib/python2.7/site-packages/system_monitor/system_monitor.py", line 281, in main
args.func(args)
File "/usr/lib/python2.7/site-packages/system_monitor/system_monitor.py", line 149, in system_monitor
time.sleep(int(interval))
TypeError: int() argument must be a string or a number, not 'NoneType'
[root@gqas013 ~]#
[root@gqas013 ~]#
The help menu says that both of them default to None,so IMHO it's be nice to handle :)