You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
on Bazel 0.25.2 seem to break the stable-status feature. I'm observing the following error
ERROR: Failed to run workspace status command bazel_tools/workspace_status.sh: /home/aj/.cache/bazel/_bazel_aj/10d2a8446c92e5dc655eb18c02f185fb/execroot/com_github_digital_asset_daml/bazel-out/stable-status.txt (Permission denied)
(Forcefully removing the file temporarily resolves the problem.)
Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
Any other information, logs, or outputs that you want to share?
Not sure if related or not, but bazel run seems to be not working on some targets when using minimal downloads. E.g. on the same commit as above
$ bazel run damlc
...
ERROR: Non-existent or non-executable /home/aj/.cache/bazel/_bazel_aj/10d2a8446c92e5dc655eb18c02f185fb/execroot/com_github_digital_asset_daml/bazel
FYI I'm still hitting this issue on bazel 0.28.1. Is there anything I can do to provide more info? When I manually delete the workspace file everything works fine.
@buchgr I don't have an exact reproducer, but the symptom is exactly the same as the original bug report. Let me know if there is any info I can provide. I've gotten around it right now by just deleting the stable-status.txt file before I run any build commands. I can remove that hack and help debug if you tell me what to look for.
@buchgr I can still reproduce the issue with the same steps given in the original issue above on current master of digital-asset/daml@f11e09f60f. This is using
$ bazel version
Build label: 0.28.1- (@non-git)
Build target: bazel-out/k8-opt/bin/src/main/java/com/google/devtools/build/lib/bazel/BazelServer_deploy.jar
Build time: Tue Jan 1 00:00:00 1980 (315532800)
Build timestamp: 315532800
Build timestamp as int: 315532800
But when you have experimental_remote_download_actions=minimal, the delete doesn't actually happen.
This is because the delete is being handled by the RemoteActionFileSystem, which looks to have a simple typo in its delete() method, fixed with this patch:
diff --git a/src/main/java/com/google/devtools/build/lib/remote/RemoteActionFileSystem.java b/src/main/java/com/google/devtools/build/lib/remote/RemoteActionFileSystem.java
index 0491c2d954..6157b413a5 100644
--- a/src/main/java/com/google/devtools/build/lib/remote/RemoteActionFileSystem.java
+++ b/src/main/java/com/google/devtools/build/lib/remote/RemoteActionFileSystem.java
@@ -69,7 +69,7 @@ public class RemoteActionFileSystem extends DelegateFileSystem {
@Override
public boolean delete(Path path) throws IOException {
RemoteFileArtifactValue m = getRemoteInputMetadata(path);
- if (m != null) {
+ if (m == null) {
return super.delete(path);
}
return true;
Activity
remote: output files need to be writable. Fixes bazelbuild#8385
remote: output files need to be writable. Fixes bazelbuild#8385
remote: output files need to be writable. Fixes bazelbuild#8385
remote: output files need to be writable. Fixes bazelbuild#8385
mattklein123 commentedon Aug 15, 2019
FYI I'm still hitting this issue on bazel 0.28.1. Is there anything I can do to provide more info? When I manually delete the workspace file everything works fine.
mattklein123 commentedon Aug 16, 2019
I verified that the above fix is in 0.28.1 so I guess it's some other issue. @buchgr LMK if you would like me to open a fresh issue on this.
buchgr commentedon Aug 16, 2019
Do you have a reproducer or is it the same as the initial bug report?
mattklein123 commentedon Aug 16, 2019
@buchgr I don't have an exact reproducer, but the symptom is exactly the same as the original bug report. Let me know if there is any info I can provide. I've gotten around it right now by just deleting the stable-status.txt file before I run any build commands. I can remove that hack and help debug if you tell me what to look for.
aherrmann commentedon Aug 20, 2019
@buchgr I can still reproduce the issue with the same steps given in the original issue above on current master of digital-asset/daml@f11e09f60f. This is using
built with Nix as defined in the same repository.
emfree commentedon Aug 25, 2019
We ran into this as well. Not very familiar with the internals here, but it looks like the issue possibly goes like this:
BazelWorkspaceStatusModulecallsFileSystemUtils.maybeUpdateContenton thestable-statusfile:bazel/src/main/java/com/google/devtools/build/lib/bazel/BazelWorkspaceStatusModule.java
Lines 193 to 197 in 4ba404f
bazel/src/main/java/com/google/devtools/build/lib/vfs/FileSystemUtils.java
Lines 766 to 770 in 4ba404f
experimental_remote_download_actions=minimal, the delete doesn't actually happen.RemoteActionFileSystem, which looks to have a simple typo in itsdelete()method, fixed with this patch:@buchgr does this seem reasonable?
buchgr commentedon Aug 27, 2019
@emfree it does. nice catch! send me a patch? :)
Make --workspace_status_command work with "Builds without the Bytes".
Make --workspace_status_command work with "Builds without the Bytes".