equal
deleted
inserted
replaced
683 |
683 |
684 def close(self, fh): |
684 def close(self, fh): |
685 """Schedule a file for closing.""" |
685 """Schedule a file for closing.""" |
686 if not self._entered: |
686 if not self._entered: |
687 raise error.Abort( |
687 raise error.Abort( |
688 _(b'can only call close() when context manager ' b'active') |
688 _(b'can only call close() when context manager active') |
689 ) |
689 ) |
690 |
690 |
691 # If a background thread encountered an exception, raise now so we fail |
691 # If a background thread encountered an exception, raise now so we fail |
692 # fast. Otherwise we may potentially go on for minutes until the error |
692 # fast. Otherwise we may potentially go on for minutes until the error |
693 # is acted on. |
693 # is acted on. |