Skip to content
This repository has been archived by the owner on Mar 3, 2023. It is now read-only.

adding bazel version check #3605

Merged
merged 1 commit into from
Aug 14, 2020
Merged

Conversation

joshfischer1108
Copy link
Member

We often have issues with users trying to build Heron with an incompatible version of Bazel. This file will hopefully help with instructing users how to get the correct version of Bazel to build Heron with. For example: If you run Bazel in the root folder with a version other than 3.4.1 it will throw an error like below:

bazel --version
ERROR: The project you're trying to build requires Bazel 3.4.1 (specified in /Users/{user}/Source/apache/incubator-heron/.bazelversion), but it wasn't found in /Users/{user}/.bazel/bin.

Bazel binaries for all official releases can be downloaded from here:
  https://github.com/bazelbuild/bazel/releases

You can download the required version directly using this command:
  (cd "/Users/joshfischer/.bazel/bin" && curl -LO https://releases.bazel.build/3.4.1/release/bazel-3.4.1-darwin-x86_64 && chmod +x bazel-3.4.1-darwin-x86_64)

Copy link
Contributor

@Code0x58 Code0x58 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this will be more helpful than adding a test in ./bazel_configure.py 👍 I'm thinking .github/ISSUES could be updated too include that kind of debugging and information (in some later PR as this is a good start)

@nicknezis
Copy link
Contributor

Cool feature. I like the idea. My only fear is that it will be a hassle when someone uses a newer Bazel. For example, if it is auto updated using brew on OSX. Is it possible to provide a range (i.e. 3.4.x)?

@Code0x58
Copy link
Contributor

I think bazelisk is the preferred way of working with .bazelversion and multiple versions

@joshfischer1108
Copy link
Member Author

joshfischer1108 commented Aug 14, 2020

The goal (to me) is to lock users into a specific version for this code. Then using some like Bazelisk like Oliver mentioned people can adjust to their needed version.

@nicknezis nicknezis merged commit c3b6433 into apache:master Aug 14, 2020
nicknezis pushed a commit that referenced this pull request Sep 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants