Fix and corresponding test for issue #137
Fix python 3 support inside PatchedTransaction (relates to issue #139)
Merge pull request #138 from tjakobsen/fix_for_137

Fix and corresponding test for issue #137