I had the problem of error_msg() being called, executing
verbose.report('Error: %s'%msg) and no message being reported. I checked
how backend_agg handles errors and deleted verbose.report() and updated
the doc string to be consistent with the way agg uses error_msg().
We now have 'verbose' and error_msg() which both report errors. The
difference is that error_msg() has the side-effect of terminating your
program, which is not necessarily what you expect from its name.
I'd prefer to delete error_msg() completely, use 'verbose' for all
errors and add a 'raise SystemExit()' after it if you need to terminate
the program. I think it would make the code easier to understand.
On Wed, 2004-11-03 at 12:48, firstname.lastname@example.org wrote:
Date: Tue, 2 Nov 2004 17:34:00 +0000
From: Jochen Voss <voss@...7...>
Subject: Re: [matplotlib-devel] questions about the PS backend
Content-Type: text/plain; charset=us-ascii
On Sun, Oct 31, 2004 at 10:33:27AM -0600, John Hunter wrote:
> >> 7) The template backend uses=3D20
> >> verbose.report('Error: %s'%msg)
> >> Should this be 'verbose.report_error' instead?
> > No verbose() at all! But I agree I think it should be
> > 'verbose.report_error'
> Yes, it should. All printing should either go to verbose.report or
> verbose.report_error, so that the user specified output handles are
> used. This was just an oversight in backend_bases.error_msg.
> Everyone should feel free to fix these as they find them.
Then the recent change to error_msg_template should be reverted,
All the best,