Re: [sqlalchemy] Baked queries vs before_execute hook

2017-10-12 Thread Martijn van Oosterhout
On Thursday, October 12, 2017 at 5:47:53 PM UTC+2, Mike Bayer wrote: > > > It sounds like you are getting back inconsistent SQL for the same > query based on some external context that is not being considered as > part of the cache key. This would indicate that you are probably > modifying the

Re: [sqlalchemy] Baked queries vs before_execute hook

2017-10-12 Thread Mike Bayer
On Thu, Oct 12, 2017 at 10:54 AM, Martijn van Oosterhout wrote: > Hi, > > Recently we've been looking into the baked query feature as a method of > speeding up query compilation. We also use a before_execute hook to modify > the query before execution to handle permission related stuff. One thing

[sqlalchemy] Baked queries vs before_execute hook

2017-10-12 Thread Martijn van Oosterhout
Hi, Recently we've been looking into the baked query feature as a method of speeding up query compilation. We also use a before_execute hook to modify the query before execution to handle permission related stuff. One thing that turned up was that when using a baked query that it cached the fin