[sqlalchemy-20] Remove ORM "from_self"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
neutron |
Fix Released
|
High
|
Rodolfo Alonso |
Bug Description
The "from_self()" method in SQLAlchemy is deprecated in version 2.0.
The from_self() method takes an ORM query object, turns it into a subquery, then returns a new query object that will SELECT from that subquery, while transparently altering subsequent criteria added to the query to be stated in terms of the subquery. The current design direction of SQLAlchemy hopes to de-emphasize the "transparently altering criteria" part of the above use case, and to move users towards a more explicit and model of usage where a subquery should be created and used explicitly using the aliased() construct, which is now very mature and can be used in ways that were not available when from_self() was first introduced.
Reference: https:/
Changed in neutron: | |
assignee: | nobody → Rodolfo Alonso (rodolfo-alonso-hernandez) |
Changed in neutron: | |
status: | New → In Progress |
Fix: https:/ /review. opendev. org/c/openstack /neutron/ +/744512