buildscripts/clang_format.py does this:
def get_clang_format_from_cache_and_extract(url, tarball_ext):
"""Get clang-format from mongodb's cache and extract the tarball."""
dest_dir = tempfile.gettempdir()
temp_tar_file = os.path.join(dest_dir, "temp.tar" + tarball_ext)
# Download from file
print("Downloading clang-format %s from %s, saving to %s" % (CLANG_FORMAT_VERSION, url,
temp_tar_file))
It tries to download, and cache, the clang-format binary into /tmp/temp.tar.gz. Unfortunately, if two Linux accounts are trying to run clang_format.py, only one can successfully download the binary.
To fix this, the cache path the script saves the tarball into should contain something unique to the account, likely the UID.