Fixed an issue in Project.py. 5_2_x

Sun, 29 Jul 2012 13:41:34 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Sun, 29 Jul 2012 13:41:34 +0200
branch
5_2_x
changeset 1962
83c766a02142
parent 1959
d43688d6aef2
child 1966
6e8945315cbc

Fixed an issue in Project.py.

Project/Project.py file | annotate | diff | comparison | revisions
--- a/Project/Project.py	Thu Jul 26 18:38:15 2012 +0200
+++ b/Project/Project.py	Sun Jul 29 13:41:34 2012 +0200
@@ -1891,8 +1891,12 @@
                 try:
                     ms = os.path.join(self.ppath, self.pdata["MAINSCRIPT"][0])
                     if not os.path.exists(ms):
-                        f = open(ms, "w")
-                        f.close()
+                        try:
+                            f = open(ms, "w")
+                            f.close()
+                        except IOError:
+                            # silently ignore it
+                            pass
                     self.appendFile(ms)
                 except IndexError:
                     ms = ""

eric ide

mercurial