MCPcopy Create free account
hub / github.com/Keeper-Security/Commander / update

Method update

keepercommander/ttk.py:46–62  ·  view source on GitHub ↗

Update the timer, and possibly issue a keepalive.

(self, params)

Source from the content-addressed store, hash-verified

44 logging.debug('Error reading logout timeout: %s', e)
45
46 def update(self, params):
47 """Update the timer, and possibly issue a keepalive."""
48 if not params.session_token:
49 return
50
51 current_time = time.time()
52
53 self.lookup_server_logout_window(params)
54
55 if (
56 self.server_logout_timer_window is not None and
57 (self.server_logout_timer_window / 2) + self.time_of_last_activity < current_time
58 ):
59 try:
60 api.send_keepalive(params)
61 except error.KeeperApiError as kae:
62 logging.warning(kae.message)
63
64
65TTK = TimeToKeepalive()

Callers 15

communicate_commandMethod · 0.45
_mock_recordMethod · 0.45
_make_resourceMethod · 0.45
base_configFunction · 0.45
make_valid_accountFunction · 0.45
make_valid_rotationFunction · 0.45
find_recordsFunction · 0.45
display_command_helpFunction · 0.45
loopFunction · 0.45
prepare_recordFunction · 0.45

Calls 2

warningMethod · 0.80