If I run the code:
connection = manager.connect(\"I2Cx\")
The program crashes and reports a KeyError because I2Cx doesn\'t exist (it should be
You should consult the documentation of whatever library is throwing the exception, to see how to get an error message out of its exceptions.
Alternatively, a good way to debug this kind of thing is to say:
except Exception, e:
print dir(e)
to see what properties e
has - you'll probably find it has a message
property or similar.