Skip to content

Commit

Permalink
Patch SessionlessContext for SA 2.0 (get method)
Browse files Browse the repository at this point in the history
  • Loading branch information
jdavcs committed Sep 20, 2023
1 parent 3379174 commit 9540ee3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/galaxy/model/store/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,9 @@ def filter_by(*args, **kwargs):

return Bunch(find=find, get=find, filter_by=filter_by)

def get(self, model_class: Type, primary_key: Any): # patch for SQLAlchemy 2.0 compatibility
return self.query(model_class).get(primary_key)


def replace_metadata_file(
metadata: Dict[str, Any],
Expand Down

0 comments on commit 9540ee3

Please sign in to comment.