AsyncSession refresh
throws exception
#6251
-
The following code throws an exception at line
Exception stacktrace:
Thanks for answering my 3rd question in a week! Really appreciate it. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 8 replies
-
I guess not, because the selectinload operation has already fired off and isn't going to associate itself with obj_a after the load. I will give you a hint, just dont use expire or refresh especially in asyncio. If you want to reload a bunch of objects, use populate existing. it does just what you want refresh to be doing and you can set whatever loader options you want, and as a bonus it wont expire things either. |
Beta Was this translation helpful? Give feedback.
I guess not, because the selectinload operation has already fired off and isn't going to associate itself with obj_a after the load.
I will give you a hint, just dont use expire or refresh especially in asyncio. If you want to reload a bunch of objects, use populate existing. it does just what you want refresh to be doing and you can set whatever loader options you want, and as a bonus it wont expire things either.