[csw-devel] SF.net SVN: gar:[17553] csw/mgar/gar/v2/lib/python/inspective_package.py

wahwah at users.sourceforge.net wahwah at users.sourceforge.net
Sun Mar 25 19:49:19 CEST 2012


Revision: 17553
          http://gar.svn.sourceforge.net/gar/?rev=17553&view=rev
Author:   wahwah
Date:     2012-03-25 17:49:18 +0000 (Sun, 25 Mar 2012)
Log Message:
-----------
pkgdb: When hachoir fails, display the exception

When indexing the whole filesystem, hachoir_parser fails on a number of
files. For now, we're catching the exception and moving on. It might
bite us later, but I have no good idea how to deal with it right now.

This change makes the exception message be printed to stdout.

Modified Paths:
--------------
    csw/mgar/gar/v2/lib/python/inspective_package.py

Modified: csw/mgar/gar/v2/lib/python/inspective_package.py
===================================================================
--- csw/mgar/gar/v2/lib/python/inspective_package.py	2012-03-25 17:48:49 UTC (rev 17552)
+++ csw/mgar/gar/v2/lib/python/inspective_package.py	2012-03-25 17:49:18 UTC (rev 17553)
@@ -66,7 +66,7 @@
         file_info["endian"] = parser["/header/endian"].display
       except hachoir_core.field.field.MissingField, e:
         logging.warning(
-            "Error in hachoir_parser processing %s", file_path)
+            "Error in hachoir_parser processing %s: %r", file_path, e)
   return file_info
 
 

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the devel mailing list