blackbox: do not nullify repo to deactivate the logger on failure
The _repo will be a mandatory attribute. Instead, make the logger to not
track any events.
--- a/hgext/blackbox.py Sun Nov 11 20:02:34 2018 +0900
+++ b/hgext/blackbox.py Sat Nov 17 20:56:25 2018 +0900
@@ -184,7 +184,7 @@
fp.write(fmt % args)
except (IOError, OSError) as err:
# deactivate this to avoid failed logging again
- self._repo = None
+ self._trackedevents.clear()
ui.debug('warning: cannot write to blackbox.log: %s\n' %
encoding.strtolocal(err.strerror))