Skip to content

Commit

Permalink
fix(qsync): NPE when trying to enable analysis for a directory or for…
Browse files Browse the repository at this point in the history
… a BUILD file
  • Loading branch information
Tomasz Pasternak committed Nov 14, 2024
1 parent fc3990b commit 6286c1a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ public ImmutableSet<DependencyTrackingBehavior> getDependencyTrackingBehaviors(L
* the set of all targets defined in all build packages within the directory (recursively).
*/
public TargetsToBuild getProjectTargets(Context<?> context, Path workspaceRelativePath) {
if (workspaceRelativePath.endsWith("BUILD")) {
if (workspaceRelativePath.endsWith("BUILD") || workspaceRelativePath.endsWith("BUILD.bazel")) {
Path packagePath = workspaceRelativePath.getParent();
return TargetsToBuild.targetGroup(allTargets().get(packagePath));
} else {
Expand Down
2 changes: 1 addition & 1 deletion shared/java/com/google/idea/blaze/common/Label.java
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public static Label of(String label) {
}

public static Label fromPackageAndName(Path packagePath, Path name) {
return of(String.format("//%s:%s", packagePath, name));
return of(String.format("@@//%s:%s", packagePath, name));
}

public static Label fromPackageAndName(Path packagePath, String name) {
Expand Down

0 comments on commit 6286c1a

Please sign in to comment.