Error calling Python API's

John Ralls jralls at
Thu Feb 21 23:33:47 EST 2013

On Feb 21, 2013, at 6:31 PM, James Nylen <jnylen+gnucash at> wrote:

> On Wed, Feb 20, 2013 at 10:47 AM, John Ralls <jralls at> wrote:
> > We'll need to know what the actual sql is and where it's coming from, so set up your python program to capture logs and set the gnc.backend.sql domain loglevel to debug. Make the error happen again and examine the resulting log to figure out the source and nature of the error, then report back.
> I'm not familiar with Python's logging system.  I tried all of these, none of which resulted in any additional output:
> logging.getLogger('gnc.backend.sql').setLevel(logging.DEBUG)
> logging.getLogger('gnc.backend.dbi').setLevel(logging.DEBUG)
> logging.getLogger('gnc.backend.*').setLevel(logging.DEBUG)
> logging.getLogger('gnc.backend').setLevel(logging.DEBUG)
> logging.getLogger('gnc').setLevel(logging.DEBUG)

It's not python logging, it's GLib logging. It's not a python program, either, nor has any effort been made to make it pythonic.
You'll need to use the C api documentation [1] to understand the program.

John Ralls


More information about the gnucash-devel mailing list