diff --git a/base/src/com/google/idea/blaze/base/sync/workspace/ArtifactLocationDecoderImpl.java b/base/src/com/google/idea/blaze/base/sync/workspace/ArtifactLocationDecoderImpl.java index 6b90a27780c..d057d58f854 100644 --- a/base/src/com/google/idea/blaze/base/sync/workspace/ArtifactLocationDecoderImpl.java +++ b/base/src/com/google/idea/blaze/base/sync/workspace/ArtifactLocationDecoderImpl.java @@ -25,6 +25,7 @@ import com.intellij.openapi.util.io.FileUtil; import java.io.File; import java.io.IOException; +import java.nio.file.NoSuchFileException; import java.nio.file.Path; import java.nio.file.Paths; import java.util.Objects; @@ -98,6 +99,8 @@ public File decode(ArtifactLocation artifactLocation) { if (pathResolver.getWorkspacePath(realFile) != null) { return realFile; } + } catch (NoSuchFileException ignore) { + // this is ok as it might not exist } catch (IOException ioException) { LOG.warn("Failed to resolve real path for " + artifactLocation.getExecutionRootRelativePath() + "\n" + ioException.getClass().getSimpleName() + ": " + ioException.getMessage()); diff --git a/base/src/com/google/idea/blaze/base/sync/workspace/ExecutionRootPathResolverImpl.java b/base/src/com/google/idea/blaze/base/sync/workspace/ExecutionRootPathResolverImpl.java index ade375adff9..b65b1020b26 100644 --- a/base/src/com/google/idea/blaze/base/sync/workspace/ExecutionRootPathResolverImpl.java +++ b/base/src/com/google/idea/blaze/base/sync/workspace/ExecutionRootPathResolverImpl.java @@ -24,6 +24,7 @@ import com.intellij.openapi.diagnostic.Logger; import java.io.File; import java.io.IOException; +import java.nio.file.NoSuchFileException; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.VisibleForTesting; @@ -131,6 +132,8 @@ public ImmutableList resolveToExternalWorkspaceWithSymbolicLinkResolution( if (workspacePathResolver.getWorkspacePath(realPath) != null) { return ImmutableList.of(realPath); } + } catch (NoSuchFileException ignore) { + // this is ok as it might not exist } catch (IOException ioException) { LOG.warn("Failed to resolve real path for " + pathInExecutionRoot, ioException); }