Building fails with "ERROR: Source forest creation failed: ... (File exists)"
See original GitHub issueIn CLion 2017.2.2 with the Bazel plugin 2017.08.29.0.2 I import this sample workspace: https://github.com/danieldanciu/clion-bazel
First time I press Sync it says it succeeds, but the second time it does an incremental build and this error is printed:
ERROR: Source forest creation failed: /private/var/tmp/_bazel_ab/fc7ea4530f9bdd4f1119eb797c96880e/execroot/__main__/bazel-clion-bazel (File exists).
You can see here the diff between the first run and the second, and the command which generated that error: https://gist.github.com/aleb/7f306b83d681f8283c2368c8f5a244c6/revisions
Command: /usr/local/bin/bazel build --tool_tag=ijwb:CLion --keep_going --experimental_build_event_binary_file=/var/folders/yd/nc6_vq355v352hm7_q86gfmw0000gn/T/intellij-bep-627b7f50-2b93-4f0d-bb2d-a5aca85aa48d --noexperimental_build_event_binary_file_path_conversion --curses=no --color=no --noexperimental_ui --noprogress_in_terminal_title --aspects=@intellij_aspect//:intellij_info.bzl%intellij_info_aspect --override_repository=intellij_aspect=/Users/ab/Library/Application Support/CLion2017.2/clwb/aspect --output_groups=intellij-info-cpp,intellij-info-py,intellij-info-generic -- //...:all //:all //bazel-clion-bazel:all
Further “Syncs” fail or succeed depending on whether it’s an incremental sync or a full sync, respectively.
Environment info
macOS 10.12.6 release 0.6.0-homebrew
Issue Analytics
- State:
- Created 6 years ago
- Reactions:2
- Comments:29 (18 by maintainers)
Ha I think in our case it’s because we have a directory called
external
at the top level checked into our repo. Removing that works around thisSomething to do with
.gitignore
🤷♂️ ? With https://github.com/wcurrie/bazel-kt-test I was seeing this error on the second sync:Until I added this to
.gitignore
:The IJ plugin does execute git for
Computing VCS working set...