fix: make pylint happy

This commit is contained in:
Lance Edgar 2026-03-05 10:24:28 -06:00
parent b247c6cd84
commit f595b67f8a
2 changed files with 6 additions and 4 deletions

View file

@ -69,13 +69,13 @@ class VersionTestCase(DataTestCase):
continuum.versioning_manager.transaction_cls = continuum.TransactionFactory() continuum.versioning_manager.transaction_cls = continuum.TransactionFactory()
self.teardown_db() self.teardown_db()
def make_config(self, **kwargs): def make_config(self, files=None, **kwargs):
""" """
Make and customize the config object. Make and customize the config object.
We override this to explicitly enable the versioning feature. We override this to explicitly enable the versioning feature.
""" """
config = super().make_config(**kwargs) config = super().make_config(files=files, **kwargs)
config.setdefault("wutta_continuum.enable_versioning", "true") config.setdefault("wutta_continuum.enable_versioning", "true")
# nb. must purge model classes from sys.modules, so they will # nb. must purge model classes from sys.modules, so they will

View file

@ -123,7 +123,7 @@ def model_transaction_query(instance, session=None, model_class=None, joins=None
query = query.outerjoin(*join_args) query = query.outerjoin(*join_args)
# we'll collect "filter conditions" for use below... # we'll collect "filter conditions" for use below...
conditions = [vercls.uuid != None] conditions = [vercls.uuid != None] # pylint: disable=singleton-comparison
# add join/filter for each requested by caller # add join/filter for each requested by caller
for child_class, foreign_attr, primary_attr in joins: for child_class, foreign_attr, primary_attr in joins:
@ -138,7 +138,9 @@ def model_transaction_query(instance, session=None, model_class=None, joins=None
) )
# and add the filter condition for use below... # and add the filter condition for use below...
conditions.append(foreign_attr != None) conditions.append(
foreign_attr != None # pylint: disable=singleton-comparison
)
# at this point we have *outer* joined on *all* version tables # at this point we have *outer* joined on *all* version tables
# involved, but that means basically "all transactions" will # involved, but that means basically "all transactions" will