functools.partal might help in some cases.
On Fri, Sep 7, 2018 at 1:44 AM <jens.troe...@gmail.com> wrote:
>
> Thank you Mike for the information, that all makes sense. I ended up with the 
> same approach that SQLA takes: a “Session” object owned by a DataManager, 
> joined to the Request’s TransactionManager. And then just pass a `dbsession` 
> and `fnsession` and `jobsession` around to functions as needed.
>
> Added yet another one or two parameters (sigh) to functions, but it keeps 
> things functional and without outside (global, thread-local) state.
>
> --
> You received this message because you are subscribed to the Google Groups 
> "pylons-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to pylons-discuss+unsubscr...@googlegroups.com.
> To post to this group, send email to pylons-discuss@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/pylons-discuss/148c7bec-2d75-4525-9aa4-3902a4a2f2cb%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.



-- 
Mike Orr <sluggos...@gmail.com>

-- 
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to pylons-discuss+unsubscr...@googlegroups.com.
To post to this group, send email to pylons-discuss@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pylons-discuss/CAH9f%3Durcme78micgQE8hT5B%2B0QdVYHUAaLW5J6t2Jy32HOqsbQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to