-
Notifications
You must be signed in to change notification settings - Fork 63
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
frontend: use ORM attributes in queries
See #3130 This is a straightforward case. We cannot join or select using attribute names represented as strings. sqlalchemy.exc.ArgumentError: Strings are not accepted for attribute names in loader options; please use class-bound attributes directly. This one is a bit harder to understand. sqlalchemy.exc.ArgumentError: expected ORM mapped attribute for loader strategy argument Easier to show on an example. When selecting e.g. `BuildChroot` and wanting to join the build information, we cannot do `join(models.Build)` but instead, we need to `join(models.BuildChroot.build)`.
- Loading branch information
Showing
3 changed files
with
91 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters