diff --git a/base/src/com/google/idea/blaze/base/sync/workspace/WorkspaceHelper.java b/base/src/com/google/idea/blaze/base/sync/workspace/WorkspaceHelper.java index 97aa05fffa7..81549609a0f 100644 --- a/base/src/com/google/idea/blaze/base/sync/workspace/WorkspaceHelper.java +++ b/base/src/com/google/idea/blaze/base/sync/workspace/WorkspaceHelper.java @@ -124,6 +124,9 @@ private static Workspace resolveWorkspace(Project project, File absoluteFile) { } BlazeProjectData blazeProjectData = getBlazeProjectData(project); + if (blazeProjectData == null) { + return null; // Project not imported yet + } Path bazelRootPath = getExternalSourceRoot(blazeProjectData); logger.debug("the bazelRootPath is " + bazelRootPath);