MCPcopy Create free account
hub / github.com/PierreGode/Ragnar / refresh

Method refresh

pager_lib/tqdm/std.py:1325–1350  ·  view source on GitHub ↗

Force refresh the display of this bar. Parameters ---------- nolock : bool, optional If `True`, does not lock. If [default: `False`]: calls `acquire()` on internal lock. lock_args : tuple, optional Passed to internal loc

(self, nolock=False, lock_args=None)

Source from the content-addressed store, hash-verified

1323 self._lock.release()
1324
1325 def refresh(self, nolock=False, lock_args=None):
1326 """
1327 Force refresh the display of this bar.
1328
1329 Parameters
1330 ----------
1331 nolock : bool, optional
1332 If `True`, does not lock.
1333 If [default: `False`]: calls `acquire()` on internal lock.
1334 lock_args : tuple, optional
1335 Passed to internal lock's `acquire()`.
1336 If specified, will only `display()` if `acquire()` returns `True`.
1337 """
1338 if self.disable:
1339 return
1340
1341 if not nolock:
1342 if lock_args:
1343 if not self._lock.acquire(*lock_args):
1344 return False
1345 else:
1346 self._lock.acquire()
1347 self.display()
1348 if not nolock:
1349 self._lock.release()
1350 return True
1351
1352 def unpause(self):
1353 """Restart tqdm timer from last print time."""

Callers 9

__init__Method · 0.95
updateMethod · 0.95
resetMethod · 0.95
set_descriptionMethod · 0.95
set_description_strMethod · 0.95
set_postfixMethod · 0.95
set_postfix_strMethod · 0.95
external_write_modeMethod · 0.80
runMethod · 0.80

Calls 3

displayMethod · 0.95
acquireMethod · 0.80
releaseMethod · 0.80

Tested by

no test coverage detected