« first day (3938 days earlier)      last day (997 days later) » 

12:57 PM
self.lock = threading.Lock()

while application_is_running():
if self.lock.locked():
# second lock check to prevent runtime exception where the lock is released inbetween the two if statements
if some_condition and self.lock.locked():
# cancel previous thread
self.lock.release()
# sleep shortly to make sure the acquire call in the thread get's the lock and not the below acquire call
time.sleep(0.001)
# acquire lock here so that the acquire call in the thread can act as an abortable sleep. Either it finishes or it gets aborted by above release
self.lock = threading.Lock()

while application_is_running():
	if self.lock.locked():
		# second lock check to prevent runtime exception where the lock is released inbetween the two if statements
		if some_condition and self.lock.locked():
		    # cancel previous thread
		    self.lock.release()
		    # sleep shortly to make sure the acquire call in the thread get's the lock and not the below acquire call
		    time.sleep(0.001)
		    # acquire lock here so that the acquire call in the thread can act as an abortable sleep. Either it finishes or it gets aborted by above release
self.lock = threading.Lock()

while application_is_running():
if self.lock.locked():
# second lock check to prevent runtime exception where the lock is released inbetween the two if statements
if some_condition and self.lock.locked():
# cancel previous thread
self.lock.release()
# sleep shortly to make sure the acquire call in the thread get's the lock and not the below acquire call
time.sleep(0.001)
# acquire lock here so that the acquire call in the thread can act as an abortable sleep. Either it finishes or it gets aborted by above release
self.lock = threading.Lock()

while application_is_running():
	if self.lock.locked():
		# second lock check to prevent runtime exception where the lock is released inbetween the two if statements
		if some_condition and self.lock.locked():
		    # cancel previous thread
		    self.lock.release()
		    # sleep shortly to make sure the acquire call in the thread get's the lock and not the below acquire call
		    time.sleep(0.001)
		    # acquire lock here so that the acquire call in the thread can act as an abortable sleep. Either it finishes or it gets aborted by above release
self.lock = threading.Lock()

while application_is_running():
if self.lock.locked():
# second lock check to prevent runtime exception where the lock is released inbetween the two if statements
if some_condition and self.lock.locked():
# cancel previous thread
self.lock.release()
# sleep shortly to make sure the acquire call in the thread get's the lock and not the below acquire call
time.sleep(0.001)
# acquire lock here so that the acquire call in the thread can act as an abortable sleep. Either it finishes or it gets aborted by above release
self.lock = threading.Lock()

while application_is_running():
if self.lock.locked():
# second lock check to prevent runtime exception where the lock is released inbetween the two if statements
if some_condition and self.lock.locked():
# cancel previous thread
self.lock.release()
# sleep shortly to make sure the acquire call in the thread get's the lock and not the below acquire call
time.sleep(0.001)
# acquire lock here so that the acquire call in the thread can act as an abortable sleep. Either it finishes or it gets aborted by above release
self.lock = threading.Lock()

while application_is_running():
    if self.lock.locked():
        # second lock check to prevent runtime exception where the lock is released inbetween the two if statements
        if some_condition and self.lock.locked():
            # cancel previous thread
            self.lock.release()
            # sleep shortly to make sure the acquire call in the thread get's the lock and not the below acquire call
            time.sleep(0.001)
            # acquire lock here so that the acquire call in the thread can act as an abortable sleep. Either it finishes or i
 

« first day (3938 days earlier)      last day (997 days later) »