commit | dd38d228cbddd946332f7733608a9c2cf40e016e | [log] [tgz] |
---|---|---|
author | Rai <agentydragon@gmail.com> | Wed Jul 28 07:13:29 2021 -0700 |
committer | Copybara-Service <copybara-worker@google.com> | Wed Jul 28 07:14:32 2021 -0700 |
tree | f6b64c96cce7c2d4a20c45703e52aa768186774a | |
parent | 0b6e892e6ca26cc82590037cd8fa77a23a4f5067 [diff] |
Recommend using --verbose_failures for debugging See this question on Stack Overflow: https://stackoverflow.com/questions/62456527/how-to-debug-remote-cache-write-failures I just had an issue with Bazel where I gave my service account rights to read and write in my GCS bucket, but I did not give it blob admin rights, and Bazel tried to do a delete, which failed with this exception: ``` WARNING: Writing to Remote Cache: com.google.devtools.build.lib.remote.BulkTransferException at com.google.devtools.build.lib.remote.RemoteCache.waitForBulkTransfer(RemoteCache.java:225) ... Suppressed: com.google.devtools.build.lib.remote.http.HttpException: 403 Forbidden ``` However, [the way the error message is created](https://github.com/bazelbuild/bazel/blob/9cc17b52abc6e05212843a9c167553b410528982/src/main/java/com/google/devtools/build/lib/remote/RemoteSpawnCache.java#L307) made it only display like this without `--verbose_failures`: ``` WARNING: Writing to Remote Cache: BulkTransferException ``` This was a very generic error, and I did not find anything online telling me how to get a better error message. Only reading the source tipped me off to the option of using `--verbose_failures`. I might also later send a PR updating `RemoteSpawnCache` to fix the error message to add something like `Pass --verbose_failures for full backtrace` if called without `--verbose_failures`. Closes #12945. PiperOrigin-RevId: 387342220
{Fast, Correct} - Choose two
Build and test software of any size, quickly and reliably.
Speed up your builds and tests: Bazel rebuilds only what is necessary. With advanced local and distributed caching, optimized dependency analysis and parallel execution, you get fast and incremental builds.
One tool, multiple languages: Build and test Java, C++, Android, iOS, Go, and a wide variety of other language platforms. Bazel runs on Windows, macOS, and Linux.
Scalable: Bazel helps you scale your organization, codebase, and continuous integration solution. It handles codebases of any size, in multiple repositories or a huge monorepo.
Extensible to your needs: Easily add support for new languages and platforms with Bazel's familiar extension language. Share and re-use language rules written by the growing Bazel community.
Follow our tutorials:
See CONTRIBUTING.md