mercurial/transaction.py
changeset 45942 89a2afe31e82
parent 45872 ec73a6a75985
child 46063 88de2639901b
--- a/mercurial/transaction.py	Fri Nov 27 17:00:00 2020 -0500
+++ b/mercurial/transaction.py	Fri Nov 27 17:03:29 2020 -0500
@@ -425,10 +425,10 @@
 
     @active
     def replace(self, file, offset):
-        '''
+        """
         replace can only replace already committed entries
         that are not pending in the queue
-        '''
+        """
         if file in self._newfiles:
             if not offset:
                 return
@@ -476,9 +476,9 @@
 
     @active
     def writepending(self):
-        '''write pending file to temporary version
+        """write pending file to temporary version
 
-        This is used to allow hooks to view a transaction before commit'''
+        This is used to allow hooks to view a transaction before commit"""
         categories = sorted(self._pendingcallback)
         for cat in categories:
             # remove callback since the data will have been flushed
@@ -489,8 +489,7 @@
 
     @active
     def hasfinalize(self, category):
-        """check is a callback already exist for a category
-        """
+        """check is a callback already exist for a category"""
         return category in self._finalizecallback
 
     @active
@@ -533,11 +532,11 @@
 
     @active
     def addvalidator(self, category, callback):
-        """ adds a callback to be called when validating the transaction.
+        """adds a callback to be called when validating the transaction.
 
         The transaction will be given as the first argument to the callback.
 
-        callback should raise exception if to abort transaction """
+        callback should raise exception if to abort transaction"""
         self._validatecallback[category] = callback
 
     @active
@@ -624,9 +623,9 @@
 
     @active
     def abort(self):
-        '''abort the transaction (generally called on error, or when the
+        """abort the transaction (generally called on error, or when the
         transaction is not explicitly committed before going out of
-        scope)'''
+        scope)"""
         self._abort()
 
     def _writeundo(self):