misc fixes

DO NOT MERGE YET