scipy dev branch breaks code