Skip to content

Commit

Permalink
better case pool_size -1
Browse files Browse the repository at this point in the history
  • Loading branch information
alex75 committed Oct 11, 2024
1 parent 0ef931f commit a67e6d2
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions cads_catalogue/database.py
Original file line number Diff line number Diff line change
Expand Up @@ -403,9 +403,7 @@ def ensure_engine(connection_string, **kwargs) -> sa.engine.Engine:
}
engine_kwargs.update(kwargs)
if engine_kwargs["pool_size"] == -1:
engine = sa.create_engine(
connection_string, poolclass=sa.pool.NullPool, **engine_kwargs
)
engine = sa.create_engine(connection_string, poolclass=sa.pool.NullPool)
else:
engine = sa.create_engine(connection_string, **engine_kwargs)
return engine
Expand Down

0 comments on commit a67e6d2

Please sign in to comment.