Skip to content
Snippets Groups Projects
Commit d53e9dc6 authored by Manuela Kuhn's avatar Manuela Kuhn
Browse files

Catched error when removing file from disc

parent 65d7ae99
No related branches found
No related tags found
No related merge requests found
......@@ -133,7 +133,12 @@ class RingBuffer:
if len(self.dataQueue) >= self.maxQueueSize:
oldFile = self.dataQueue.pop()
self.log.debug("Remove file from disc: " + str(oldFile) )
os.remove(oldFile)
try:
os.remove(oldFile)
except Exception as e:
self.log.debug("Unable to remove file from disc: " + str(oldFile) )
self.log.debug("Error was: " + str(e) )
self.dataQueue.appendleft(path)
self.log.debug("Adding File to Queue: " + str(path) )
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment