Mtrumpis mt fixups

This solves the merge conflicts with upstream/master and also solves an issue that came up when testing this without the cython extension compiled.