PY-21454: Use project dir if directory not provided