Miscellaneous fixes before NEST