IP python bindings: deal with #151 and #122