Fix various issues seen in CI.