String index out of range

Johannes Stezenbach js at sig21.net
Wed Dec 15 20:02:54 GMT 2010


On Wed, Dec 15, 2010 at 07:25:42PM +0100, Nicolas Sebrecht wrote:
> On Wed, Dec 15, 2010 at 05:20:04PM +0100, Johannes Stezenbach wrote:
> > On Wed, Dec 15, 2010 at 10:16:39AM -0500, Graham Dunn wrote:
> 
> > > Account sync Test: DEBUG[imap]: dequote() called with input: ""
> > > Account sync Test: DEBUG[imap]: dequote() returning:
> > > Account sync Test: DEBUG[imap]: dequote() called with input:
> > > Account sync Test: WARNING: Error occured attempting to sync account
> > > Test: string index out of range
> > 
> > And another time this ill-devised WARNING prevents us from getting
> > a useful backtrace :-(
> 
> Why not wipe out them, then?

Well, it was added with good intentions in 30344587d9:

  "if one account has an error because of a changed password or something
   that should not affect the other accounts."

There are some possible ways out:
- print the trace back manually but keep the exception handling as-is
- change the catch-all "except" to something more specific
  like "except IOError" etc., but crash on software bugs
  with a traceback
- add a commandline/config option to disable this try: ... except:
  (or maybe disable if when debug is enabled)

Johannes




More information about the OfflineIMAP-project mailing list