Browser Steps - When cleaning up old screenshots, check the file exists

pull/1689/head
dgtlmoon 1 year ago
parent aaceb4ebad
commit 7cb7eebbc5

@ -201,6 +201,7 @@ class Fetcher():
dest = os.path.join(self.browser_steps_screenshot_path, 'step_*.jpeg') dest = os.path.join(self.browser_steps_screenshot_path, 'step_*.jpeg')
files = glob.glob(dest) files = glob.glob(dest)
for f in files: for f in files:
if os.path.isfile(f):
os.unlink(f) os.unlink(f)

Loading…
Cancel
Save