changeset 46788:693991ccfc49 stable

crecord: null out the curses attribute with `None` on failure to import Pytype got really confused that this could be `Union[module, bool]`, and spewed about tons of attributes that are not available on `bool`. Differential Revision: https://phab.mercurial-scm.org/D10210
author Matt Harbison <matt_harbison@yahoo.com>
date Fri, 12 Mar 2021 19:02:07 -0500
parents 70f8c64812db
children 914ca0a98518
files mercurial/crecord.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/crecord.py	Sat Mar 13 00:41:37 2021 -0500
+++ b/mercurial/crecord.py	Fri Mar 12 19:02:07 2021 -0500
@@ -64,7 +64,7 @@
 
     curses.error
 except (ImportError, AttributeError):
-    curses = False
+    curses = None
 
 
 class fallbackerror(error.Abort):