Last 12 weeks · 1634 commits
4 of 6 standards met
Problem: We have local execution, and there's no easy to reach for buck command for getting the action cache digests of things that were uploaded. Furthermore, buck log what-uploaded is too tempting to reach for (yet is surprisingly the wrong tool). Solution: Make buck log what-uploaded print out the digests of the action cache entries uploaded in a build. Test plan:
Problem: Tests (including but not limited to Haskell) sometimes use the libc locales to interact with character sets; by default LANG=C and this causes corruption of UTF-8 text being passed through various libc text functions (it's real bad in Haskell where you can't print some UTF-8 to stdout without throwing an exception!). Buck2 eats those environment variables (including LANG), so that these tests are always broken. I presume Meta defaults this to something deterministic in tpx somewhere. Solution: If buck2 is going to eat the env-vars, it's probably best that we make it have reasonable behaviour for those who haven't yet noticed being bitten by their programs running in the C locale. Weakly default to C.UTF-8 for LC_CTYPE when running tests. Allow basically anything to override it: --env, invoker's environment, etc. We eat all other locale variables, which wind up defaulting to C (which is fine). I checked with an agent that with C.UTF-8 and en_US.UTF-8 the transliteration to ascii is the same. Collation order is codepoint order with C.UTF-8 unlike en_US where it is more human-friendly. Uncertainties: I don't know if it's smart to take what the caller environment contains for LC_CTYPE. That decision could go either way, to be honest: buck is pretty aggressive on test confinement, but on the other hand, it's an explicit signal from the user.
Context A monorepo setup with Buck2 build. I have a holding all the config details including for remote builds. Issue In my the remote build section looks like: Since I want to do remote builds via CI as well, I was planning to create another file like which shall hold the certs and build like : Expected The Buck2 client merges the configs (as it does when users have a and on their dev setup locally) and does the build. Actual It fails with or . If I copy paste the key-value pairs mentioned in to itself and run, it works smoothly. What changed? We were earlier using to pass token for auth with our RBE. In we kept the token as an environment variable (which would be exposed via CI) and for developers, they could simply override via Constraints I can't put these certs in as we want developers to use the JWT token method only. Note** I also tried using as mentioned in https://buck2.build/docs/concepts/buckconfig/#precedence-of-buck2-configuration-specifications but didn't help.
python_bootstrap_toolchain.interpreter -> exec_dep. Every python_bootstrap_binary in the prelude is a build tool. python_toolchain.compile -> exec_dep. It is read by the bytecode compile action in prelude/python/compile.bzl. Split host_interpreter out of interpreter. make_py_package already passes them to the packaging tool as separate --python/--host-python flags, so this is a distinction upheld by the rest of the prelude. We introduce a macro to retain source compatibility. Fix system_python_bootstrap_toolchain to properly consider the exec platform when determining the name of the interpreter, rather than doing it based on target platform. related to #1465: this sort of independently fixes the python binaries to work correctly (by forcing them to use the exec platform's interpreter, which is the only correct choice for bootstrap binaries), though it's still correct to transition them to exec configuration as that PR does.
Repository: facebook/buck2. Description: Build system, successor to Buck Stars: 4406, Forks: 389. Primary language: Rust. Languages: Rust (56.7%), Starlark (19.7%), Java (11.6%), Python (7.8%), Kotlin (2.1%). License: Apache-2.0. Homepage: https://buck2.build/ Open PRs: 84, open issues: 288. Last activity: 15m ago. Community health: 75%. Top contributors: stepancheg, JakobDegen, krallin, ndmitchell, Nero5023, cjhopman, christolliday, iguridi, scottcao, bobyangyf and others.