Every line of 'python pause' code snippets is scanned for vulnerabilities by our powerful machine learning engine that combs millions of open source libraries, ensuring your Python code is secure.
186 def pause() -> None: 187 """ 188 Pauses the process until a signed is received. 189 Windows does not have a signal.pause() so we waste a few more cpu cycles. 190 :return: None 191 """ 192 if os.name == "nt": 193 while True: 194 time.sleep(60) 195 else: 196 signal.pause()
41 def pause(duration): 42 ''' basic sleep with periodic logging (to show progess) ''' 43 interval = 10 44 tick = duration / interval 45 for i in xrange(interval): 46 logger.info(u"Pause (%dmn) Elapsed: %dmn" % (duration / one_minute, 47 tick * i / one_minute)) 48 time.sleep(tick)