837 packageFile = os.path.join(packagePath, "__init__.py") |
837 packageFile = os.path.join(packagePath, "__init__.py") |
838 if not os.path.exists(packageFile): |
838 if not os.path.exists(packageFile): |
839 try: |
839 try: |
840 with open(packageFile, "w", encoding="utf-8"): |
840 with open(packageFile, "w", encoding="utf-8"): |
841 pass |
841 pass |
842 except IOError as err: |
842 except OSError as err: |
843 E5MessageBox.critical( |
843 E5MessageBox.critical( |
844 self, |
844 self, |
845 self.tr("Add new Python package"), |
845 self.tr("Add new Python package"), |
846 self.tr( |
846 self.tr( |
847 """<p>The package file <b>{0}</b> could""" |
847 """<p>The package file <b>{0}</b> could""" |