diff --git a/src/caosdb/exceptions.py b/src/caosdb/exceptions.py
index 4ff840a64a11681ea2f9c360cd0f8b48a41a7b82..3b3d2ce4c23907f62ec1515e853c3eb2aeef7013 100644
--- a/src/caosdb/exceptions.py
+++ b/src/caosdb/exceptions.py
@@ -135,7 +135,7 @@ class ResourceNotFoundException(CaosDBException):
         CaosDBException.__init__(self, msg=msg)
 
 
-######################### Transaction errors #########################
+# ######################### Transaction errors #########################
 
 
 class TransactionError(CaosDBException):
@@ -246,7 +246,7 @@ class TransactionError(CaosDBException):
 
     def get_container(self):
         """Return the Container object that contained the problematic
-        entities.  
+        entities.
 
         Returns
         -------
diff --git a/unittests/test_error_handling.py b/unittests/test_error_handling.py
index 2b079a02859327122687e4ee784a5f0fabe3f84e..d677bba5c6cab53703dc0f492d2289d63ca5b6ba 100644
--- a/unittests/test_error_handling.py
+++ b/unittests/test_error_handling.py
@@ -242,13 +242,13 @@ def test_parent_and_properties_errors():
         if err.get_code() == parent_code:
             found_parent = True
             assert err.errors[0].entity.name == parent.name
-            assert not prop1.name in [x.name for x in
+            assert prop1.name not in [x.name for x in
                                       err.all_entities]
-            assert not prop2.name in [x.name for x in
+            assert prop2.name not in [x.name for x in
                                       err.all_entities]
         elif err.get_code() == prop_code:
             found_prop = True
-            assert not parent.name in [x.name for x in
+            assert parent.name not in [x.name for x in
                                        err.all_entities]
             for sub_err in err.errors:
                 if sub_err.get_code() == entity_code:
@@ -303,7 +303,7 @@ def test_container_with_faulty_elements():
     assert te.get_code() == container_code
     # no healthy entity caused an error
     for good in [good_rec, good_prop]:
-        assert not good in te.all_entities
+        assert good not in te.all_entities
     # all records that caused problems
     assert {rec_name, rec_auth, rec_par_prop}.issubset(te.all_entities)
     # the container error contains the errors caused by the records