From: John Napiorkowski Date: Sun, 29 Jun 2014 15:10:07 +0000 (-0400) Subject: reluctantlt move setup_trace before setup_plugins (we want it for use in plugins) X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=commitdiff_plain;h=ancona-trace reluctantlt move setup_trace before setup_plugins (we want it for use in plugins) --- diff --git a/lib/Catalyst.pm b/lib/Catalyst.pm index c5f9f78..66b8707 100755 --- a/lib/Catalyst.pm +++ b/lib/Catalyst.pm @@ -1030,12 +1030,12 @@ Calling C<< $c->debug(1) >> has no effect. =head2 Effects of debug mode -On older versions of L debug mode would enable verbose -application level logging (for example when starting in debug you -get the startup information at the console regarding loaded models, +On older versions of L (prior to version 5.90070) debug mode would +enable verbose application level logging (for example when starting in debug +you get the startup information at the console regarding loaded models, controllers, etc. as well as additional request / response tracing. -It would also enable the default debugging error page that gives -you error details and a stack track. +It would also enable the default debugging error page that gives you error +details and a stack track. On newer versions of L we have a new application tracing system. See L for details. In general trace replaces @@ -1153,8 +1153,8 @@ sub setup { $class->setup_home( delete $flags->{home} ); $class->setup_log( delete $flags->{log} ); - $class->setup_plugins( delete $flags->{plugins} ); $class->setup_trace(); + $class->setup_plugins( delete $flags->{plugins} ); $class->setup_data_handlers(); $class->setup_dispatcher( delete $flags->{dispatcher} ); @@ -2924,7 +2924,8 @@ sub psgi_app { =head2 trace_level Class attribute which is a positive number and defines the noiseness of the -application trace. See L. +application trace. This attribute is defined at application startup, trying +to change it in a running app is considered an error. See L. =head2 trace_logger @@ -3925,6 +3926,10 @@ You may also configure tracing via configuration: __PACKAGE__->setup; +B You cannot set tracing via configuration files if you are using +the L plugin, as that plugin is loaded too +late for it to be applied during all phases of setup. + Or, you may set tracing via environment varables, for example: CATALYST_TRACE=1 perl script/myapp_server.pl