Show More
@@ -939,9 +939,9 b' def _exceptionwarning(ui):' | |||
|
939 | 939 | worst = None, ct, '' |
|
940 | 940 | if ui.config('ui', 'supportcontact') is None: |
|
941 | 941 | for name, mod in extensions.extensions(): |
|
942 | testedwith = getattr(mod, 'testedwith', '') | |
|
943 | if pycompat.ispy3 and isinstance(testedwith, str): | |
|
944 | testedwith = testedwith.encode(u'utf-8') | |
|
942 | # 'testedwith' should be bytes, but not all extensions are ported | |
|
943 | # to py3 and we don't want UnicodeException because of that. | |
|
944 | testedwith = util.forcebytestr(getattr(mod, 'testedwith', '')) | |
|
945 | 945 | report = getattr(mod, 'buglink', _('the extension author.')) |
|
946 | 946 | if not testedwith.strip(): |
|
947 | 947 | # We found an untested extension. It's likely the culprit. |
@@ -976,11 +976,7 b' def _exceptionwarning(ui):' | |||
|
976 | 976 | bugtracker = _("https://mercurial-scm.org/wiki/BugTracker") |
|
977 | 977 | warning = (_("** unknown exception encountered, " |
|
978 | 978 | "please report by visiting\n** ") + bugtracker + '\n') |
|
979 | if pycompat.ispy3: | |
|
980 | sysversion = sys.version.encode(u'utf-8') | |
|
981 | else: | |
|
982 | sysversion = sys.version | |
|
983 | sysversion = sysversion.replace('\n', '') | |
|
979 | sysversion = pycompat.sysbytes(sys.version).replace('\n', '') | |
|
984 | 980 | warning += ((_("** Python %s\n") % sysversion) + |
|
985 | 981 | (_("** Mercurial Distributed SCM (version %s)\n") % |
|
986 | 982 | util.version()) + |
General Comments 0
You need to be logged in to leave comments.
Login now