various bug fixes
0.5.5