No problem on run...

This commit is contained in:
Nicolas Hennion 2014-03-28 09:30:36 +01:00
parent e0bbd65b4d
commit be2ddb1a84
3 changed files with 4 additions and 8 deletions

View File

@ -33,13 +33,9 @@ class GlancesStandalone():
# Init stats
self.stats = GlancesStats(config)
# Initial update
# !!! The first time Glances display wrong CPU/MEM information
# Initial system informations update
self.stats.update()
# !!! Usefull ?
self.refresh_time = args.time
# Init HTML output
# !!! TODO
# if html_tag:

View File

@ -41,6 +41,7 @@ class glancesCurses:
# Init args
self.args = args
# By default, display bitrate instead of cumulative in the network plugin
self.args.network_stats_cumulative = False
@ -56,6 +57,7 @@ class glancesCurses:
self.screen = curses.initscr()
if not self.screen:
print(_("Error: Cannot init the curses library.\n"))
sys.exit(1)
# Set curses options
if hasattr(curses, 'start_color'):

View File

@ -58,9 +58,7 @@ class Plugin(GlancesPlugin):
"""
# Grab CPU using the PSUtil cpu_times_percent method
# !!! the first time this function is called with interval = 0.0 or None
# !!! it will return a meaningless 0.0 value which you are supposed to ignore
cputimespercent = cpu_times_percent(interval=0, percpu=False)
cputimespercent = cpu_times_percent(interval=0.0, percpu=False)
# Get all possible value for CPU stats
# user