Skip to content

Commit 657861f

Browse files
committed
Merge pull request #1543 from HelioGuilherme66/fix_#1539
Fixes #1539, by adding exception handling when in Windows.
2 parents bf04078 + f390b11 commit 657861f

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/robotide/log/log.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
import uuid
1919
import atexit
2020
import glob
21+
import sys
2122

2223
from robotide.pluginapi import Plugin, ActionInfo, RideLog
2324
from robotide import widgets
@@ -51,10 +52,11 @@ def _close(self):
5152

5253
def _remove_old_log_files(self):
5354
for fname in glob.glob(
54-
os.path.join(tempfile.gettempdir(), '*ride.log')):
55+
os.path.join(tempfile.gettempdir(), '*-ride.log')):
5556
try:
5657
os.remove(fname)
57-
except IOError:
58+
except OSError or IOError as e:
59+
sys.stderr.write(e)
5860
pass
5961

6062
@property

0 commit comments

Comments
 (0)