--- a/eric6/Plugins/VcsPlugins/vcsMercurial/hg.py Thu Apr 15 16:52:05 2021 +0200 +++ b/eric6/Plugins/VcsPlugins/vcsMercurial/hg.py Thu Apr 15 18:11:24 2021 +0200 @@ -1902,7 +1902,7 @@ lfMinSize, lfPattern = dlg.getLargefilesData() else: createContents = False - try: + with contextlib.suppress(OSError): with open(cfgFile, "w") as cfg: if createContents: # write the data entered @@ -1925,8 +1925,6 @@ "\n ".join(lfPattern))) self.__monitorRepoIniFile(repoName) self.__iniFileChanged(cfgFile) - except OSError: - pass self.repoEditor = MiniEditor(cfgFile, "Properties") self.repoEditor.show()