Re: RFC: Apache::Carp - Error Handling under mod_perl

2000-12-01 Thread Matt Sergeant
On Fri, 1 Dec 2000, Gunther Birznieks wrote: The other thing that worries me is that even if you sneak the code back into the PageKit hierarchy you are still not doing everything Lincoln is doing to help deal with eval issues. This is a particularly thorny problem (and I suspect part of the

Re: RFC: Apache::Carp - Error Handling under mod_perl

2000-11-30 Thread Gunther Birznieks
Can you help by explaining what this does that is different from CGI::Carp? What are you doing that is Apache specific? Could CGI::Carp do the job? If there was something you needed added to CGI::Carp, would it make sense for you to add the apache-specific function flag to CGI::Carp instead of

Re: RFC: Apache::Carp - Error Handling under mod_perl

2000-11-30 Thread Matt Sergeant
On Thu, 30 Nov 2000, Gunther Birznieks wrote: Can you help by explaining what this does that is different from CGI::Carp? What are you doing that is Apache specific? Could CGI::Carp do the job? If there was something you needed added to CGI::Carp, would it make sense for you to add the

Re: RFC: Apache::Carp - Error Handling under mod_perl

2000-11-30 Thread Thomas J. Mather
Sure. I have attached Apache/Carp.pm, so you can examine it. Some of the main differences that can't be implemented easily under CGI are: * Apache::Carp can be configured in the httpd.conf file to send an e-mail to the server admin by setting 'PerlSetVar APACHE_CARP_HANDLER email'. This way

Re: RFC: Apache::Carp - Error Handling under mod_perl

2000-11-30 Thread Thomas J. Mather
I forgot to include the Apache/Carp.pm attachment in my last e-mail. Here it is. package Apache::Carp; # $Id: $ use integer; use strict; use Mail::Mailer; # trap die and warn $main::SIG{__WARN__} = \Apache::Carp::warn; $main::SIG{__DIE__} = \Apache::Carp::die;

Re: RFC: Apache::Carp - Error Handling under mod_perl

2000-11-30 Thread Gunther Birznieks
OK, I can see the advantage of the Apache specific stuff. However, in looking at your code, I think you may not be taking into account a lot of eval logic that CGI::Carp has. Eval logic is the hardest to get right (and I bet there are still bugs) because SIG die is still called within an eval.

Re: RFC: Apache::Carp - Error Handling under mod_perl

2000-11-30 Thread Thomas J. Mather
OK, I think Apache::Carp was a misleading name - it is not really a replacement for CGI::Carp - instead it is a simple module for reporting errors under a mod_perl enviroment that is easy to use and doesn't require that the programmer use carp and croak. A better name would have been something

Re: RFC: Apache::Carp - Error Handling under mod_perl

2000-11-30 Thread Gunther Birznieks
I didn't mean for you to withdraw. I would encourage you to still make it Apache::Carp. But then to avoid confusion model it more after CGI::Carp while adding the features you wanted for Apache::PageKit. As a person who has hacked and debugged the internals of CGI::Carp and looking at your

Re: RFC: Apache::Carp - Error Handling under mod_perl

2000-11-30 Thread Thomas J. Mather
Yes it would be useful to have an Apache::Carp as Gunther described it, but I don't really have the time right now to develop it. Maybe I'll get the time to later, but in the meanwhile, I'll stick with the current module in PageKit (it works well with code written under PageKit). If anybody

RFC: Apache::Carp - Error Handling under mod_perl

2000-11-29 Thread T.J. Mather
I've done a lot of programming under mod_perl and I got tired of examining the error logs for errors. So I wrote a module that displays to the broswer the error (with a complete call stack) for any fatals or warnings that occur on a development server (similar to using CGI::Carp

Re: RFC: Apache::Carp - Error Handling under mod_perl

2000-11-29 Thread Dave Rolsky
On Thu, 30 Nov 2000, T.J. Mather wrote: I've done a lot of programming under mod_perl and I got tired of examining the error logs for errors. So I wrote a module that displays to the broswer the error (with a complete call stack) for any fatals or warnings that occur on a development server