Usually the best way to achieve this is: - Through the environment_loaded milestone if you need it to happen once per process ( http://turbogears.readthedocs.io/en/latest/turbogears/configuration/appconfig.html#configuration-milestones ) - Through the configure_new_app hook if you need it to happen once for each TG application created by a process ( http://turbogears.readthedocs.io/en/latest/turbogears/hooks.html#available-hooks )
On Mon, May 30, 2016 at 10:00 AM, Bastien Sevajol <[email protected] > wrote: > Hi, > > I need to execute code once my application is itilialized and ready to use > (auth methods usage, etc). > Place my code in tg.configuration.app_config.AppConfig#after_init_config > is right place ? > > To expose my situation: I want to launch in subprocess, a radicale server > instance who use my app auth methods. > > Thank's, > Bastien. > > -- > You received this message because you are subscribed to the Google Groups > "TurboGears" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at https://groups.google.com/group/turbogears. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "TurboGears" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/turbogears. For more options, visit https://groups.google.com/d/optout.

