Switching to the built-in json module, with a fallback to the external one
authorEd Page <eopage@byu.net>
Fri, 12 Aug 2011 01:40:50 +0000 (20:40 -0500)
committerEd Page <eopage@byu.net>
Fri, 12 Aug 2011 01:40:50 +0000 (20:40 -0500)
ejpi/ejpi_qt.py

index 00dea95..31576c5 100755 (executable)
@@ -4,7 +4,11 @@
 from __future__ import with_statement
 
 import os
-import simplejson
+try:
+       import json as simplejson
+except ImportError:
+       print "json not available, falling back to simplejson"
+       import simplejson
 import string
 import logging
 import logging.handlers