MCPcopy Create free account
hub / github.com/cppla/ServerStatus / get_uptime

Function get_uptime

clients/client-linux.py:63–66  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

61CM = _env_str("CM", CM)
62
63def get_uptime():
64 with open('/proc/uptime', 'r') as f:
65 uptime = f.readline().split('.', 2)
66 return int(uptime[0])
67
68def get_memory():
69 re_parser = re.compile(r'^(?P<key>\S*):\s*(?P<value>\d*)\s*kB')

Callers 1

client-linux.pyFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected