bug fixes as test of roundtripping usin all 9 run modes