add some fixes for issues discovered during sage days