Once the asserts are fixed, I think this PR is good to be merged.