File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed 
base/src/com/google/idea/blaze/base/sync/workspace Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change 11/* 
2-  * Copyright 2016  The Bazel Authors. All rights reserved. 
2+  * Copyright 2025  The Bazel Authors. All rights reserved. 
33 * 
44 * Licensed under the Apache License, Version 2.0 (the "License"); 
55 * you may not use this file except in compliance with the License. 
2525import  com .intellij .openapi .util .io .FileUtil ;
2626import  java .io .File ;
2727import  java .io .IOException ;
28+ import  java .nio .file .Files ;
29+ import  java .nio .file .NoSuchFileException ;
2830import  java .nio .file .Path ;
2931import  java .nio .file .Paths ;
3032import  java .util .Objects ;
@@ -93,6 +95,11 @@ public File decode(ArtifactLocation artifactLocation) {
9395  private  @ Nullable  File  tryToResolveExternalArtifactToMainWorkspace (ArtifactLocation  artifactLocation ) {
9496    if  (artifactLocation .isExternal ()) {
9597      try  {
98+         Path  estimatedLocation  = blazeInfo .getExecutionRoot ().toPath ().resolve (artifactLocation .getExecutionRootRelativePath ());
99+         if  (!Files .exists (estimatedLocation )) {
100+           return  null ;
101+         }
102+ 
96103        File  realFile  = blazeInfo .getExecutionRoot ().toPath ()
97104            .resolve (artifactLocation .getExecutionRootRelativePath ()).toRealPath ().toFile ();
98105        if  (pathResolver .getWorkspacePath (realFile ) != null ) {
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments