Adding exception binding for Java and Python