So I have a AMD machine with many cores and 32GB of memory. When I do `pip install -e .`, my machine crashes since bazel tries to use all the cores, but quickly runs out of memory. It seems there is no native way to set environment variables to tell bazel to limit its resource consumption, but there is a `--local_cpu_resources` command-line option.
This PR exposes that to the `pip install` via an environment variable. I also went through the setup.py and documented all the environment variables I could find.
* Update Bazel (to 3.4.1), gRPC, boringssl, absl.
* Always reinstall Bazel if needing to upgrade to a new Bazel version.
* Add patch for properly detecting Windows Python headers when building gRPC.
* Add minimum Bazel version check.
* Update docs with new Bazel version.
* Added build instructions for Windows
* Fixed minor indentantion issue
* Addressing code review comments
* Fixed minor indentation issues
* Fixed minor punctuation issue
* Added bazel to requirements list
* Fixed git download link.
Co-authored-by: Ian Rodney <ian.rodney@gmail.com>
* Added explanation for need to enable Developer Mode
* Moving Fast, Debug, and Optimized Builds one level up
* Added pytest to Windows requirements. Removed old dangling Windows text from Linux build instructions
Co-authored-by: Ian Rodney <ian.rodney@gmail.com>
* Fast builds by default
* Update doc/source/development.rst
Co-authored-by: Simon Mo <xmo@berkeley.edu>
Co-authored-by: Mehrdad <noreply@github.com>
Co-authored-by: Simon Mo <xmo@berkeley.edu>
* Make wget quiet
* Make sphinx-build quiet
* Remove -q from pip install in CI script as config already takes care of it
* Add documentation on custom dependencies
* formatting
* python
* Added small section on installation when using Anaconda. Also fixed an obsolete link to Anaconda.
* Delete more temporary directories when running the doc "make clean".
* Added a link to the docs for building and contributing
* Minor comment
Rename `xray_test.py` to `mini_test.py` and use that in the documentation. Right now we suggest that people run `runtest.py`, but that often doesn't succeed and takes too long.
* Allow yapf to lint individual files
* Add tip for using yapf
* Update doc
* Update script to autoformat changed py files
The new default is for the script to only updated changed files to encourage
using it as a pre-push hook. Travis still checks all since it's not that big an
increase to runtime.
* Exclude formatting thirdparty/autogen py files
* Symlink .travis -> scripts
Hidden directories may get glossed over otherwise.
* .travis -> scripts in docs
They are symlinks to the same thing, but `scripts` is more dev-friendly, while
`.travis` is really only for Travis CI.
* Document different yapf format functions
Most devs will only need `format_changed`, and this is run by default.
`format_changed` should be fast enough in most cases to work as a pre-commit
hook.
* Speed up yapf by only formatting changed files
* Update docs
1. Mention how yapf can be used a pre-commit hook
2. rm `bash`, script is executable
* Update yapf.sh
* Update development.rst
* Update yapf.sh
* Use bash arrays for correct argument splitting
Playing fast and loose with whitespace in bash is a terrible idea.
* Only format non-excluded by default
* Check changes against master
Normally, the remote is called `origin`, but naming it explicit
* Adding missing directory to `format_all`
* Cleanup YAPF code
Remove unused function and move around code to make clearer and adding lines
give cleaner diffs.
* Ensure correct files are autoformatted
* Fix cmd line arg splitting
Each arg has to be in its own set of quotes.
* Diff against mergebase
TIL there's a clean syntax for doing that, but it's too clever to belong in a
shell script.
We use `mapfile -t` to ensure no problems down the line with weird filenames.