summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2025-06-18bootstrap.py: Small readability improvementv1.6.0-alpha+20250618Paul Cristian Sarbu
2025-06-18Invocation server: directly show only artifactKlaus Aehlig
When presenting a build, the output artifacts are hidden behind a "details" environment to not overload the user with long list of, e.g., test results (especially if generated by a test matrix). If, however, only a single artifact is built, there is no reason to hide it; so simply show it.
2025-06-18Add auto-formatting of json fileKlaus Aehlig
Given the just added json-file formatter, we can generate a diff formatting properly all json files, i.e., all target, rules, and expression files, by applying that formatter to every target file and combining the patches. A target description doing precisely this can easily be obtained as computed root. In this way, we also make good use of caching. To avoid doing recomputing the target description unnecessarily, we factor through the tree structure of the repository tree; the latter, we obtain from the to-git view of the top-level directory, whereas for computing the diff we use the actual (not necessarily committed) files.
2025-06-18Add json formater for target filesKlaus Aehlig
... that is aware of the order-independent fields in our C++ rules. Co-authored-by: Maksim Denisov <denisov.maksim@huawei.com> Co-authored-by: Oliver Reiche <oliver.reiche@huawei.com> Co-authored-by: Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com> Co-authored-by: Alberto Sartori <alberto.sartori@huawei.com>
2025-06-18Add script applying the clang-format diffKlaus Aehlig
Our lint target already provides a target for the diff obtained from clang format. Add a convenience script computing and applying that patch.
2025-06-18Update importsKlaus Aehlig
2025-06-17lint scripts: Add typing and basic documentationPaul Cristian Sarbu
2025-06-17lint: add single-file overall reportKlaus Aehlig
To quickly understand where the problems found by the linter are, an overall report can be useful, so that just-mr --main lint build -P REPORT immediately shows the problems found in the code. For convenience, also include the patch to be applied to fix formating in the default target.
2025-06-16lint: add strict_depsKlaus Aehlig
Add a test verifying that no header files are picked up from an indirect dependency.
2025-06-16Add lint target for iwyuKlaus Aehlig
Co-authored-by: Maksim Denisov <denisov.maksim@huawei.com> Co-authored-by: Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com>
2025-06-16Export test distfilesPaul Cristian Sarbu
Remove the test tainting of the distfiles target used in the large tests and instead make an export target, as it is purely a source tree. In this way, the distfiles tree can be truly absent and the large tests can now also be delegated to the serve endpoint.
2025-06-16Avoid unnecessary work in accessing container entriesPaul Cristian Sarbu
- in sequence containers, use operator[] instead of .at() when accessing indices guaranteed to be in bound; - in associative containers, prefer .find() and reusing the returned const iterator to using .contains() and .at(); while there, make any so obtained iterators const if they are read-only.
2025-06-16clang-tidy: use bundled header filesKlaus T. Aehlig
A typical compiler implicitly adds some search directories for system headers; those might not be obvious for the bootstrapped clang-tidy. Therefore, use the bundled headers of the clang toolchain. This has the additional advantage, that everyone uses the same system headers for linting.
2025-06-16Ensure equality operators are really noexcept.Klaus T. Aehlig
... by explicitly catching any possible exception. Mainly to make clang-tidy happy. ...
2025-06-13Test: Fix flaky LargeObjectCAS test.Maksim Denisov
Due to a random nature of the LargeObjectUtils generator, it may generate 2 identical files in a row. To prevent the test from failing, check that a newly generated file doesn't collide with any already added to the CAS.
2025-06-13Extend invocation-logging tutorialKlaus Aehlig
Environment variables can be used to provide some context, why a particular invocation was run, and hence allow additional sharding. Also, remind that setting up a cronjob for log rotation might me a good idea.
2025-06-13Update bootstrapping documentationKlaus Aehlig
... mentioning that now etc/repos.in.json is used for bootstrapping. This is relevant for both, determining the precise list of dependencies needed as well as for patching the repository configuration, e.g., in a package build.
2025-06-13CONTRINBUTING: point to the newly added "lint" repositoryKlaus Aehlig
To allow everyone to lint in the same way with minimal manual setup effort.
2025-06-13Add lint target for clang-formatKlaus Aehlig
2025-06-13Add a lint target for clang-tidyKlaus Aehlig
... using the already-committed configuration file and the version of clang-tidy that was imported from the toolchain.
2025-06-13bootstrap: use etc/repos.in.jsonKlaus Aehlig
... as repository configuration. We know that everything imported is not needed for the bootstrap process. Hence, by taking the description before import, we can avoid fetching unnecessary archives.
2025-06-13Import clang-18 from toolchainKlaus Aehlig
... and make it available to a new "lint" repository. In this way, there is no dependency of the main or test repository on the newly importet toolchain, while the "lint" repository has access to a well-defined version of clang-tidy.
2025-06-12Update documentationMaksim Denisov
2025-06-12Test compactification gets skipped for `gc --all`Maksim Denisov
2025-06-12Add a flag to `gc` command: `--all`Maksim Denisov
2025-06-12GarbageCollector: Support removal of all generations at onceMaksim Denisov
...that ignores compactification.
2025-06-11Add design document for full GCMaksim Denisov
2025-06-05lint tutorial: hint on the discovered but not processed actionsKlaus Aehlig
Linting is a natural example where actions are discovered that are not neded for the artifact that is requested to be built. Use this opportunity to explain the difference between discovering an action and processing it.
2025-06-05test ["end-to-end/git-import", "computed"]: move to subdirKlaus Aehlig
This test uses a file repository at "." with the "to_git" pragma. Now, if we build the tool to be tested in debug mode, the sources end up in the test's action directory. If we take the work dir of the simulated use case top level, all these sources end up unnecessarily in the workspace root of the test repo. Avoid this overhead by moving to a subdirectory.
2025-06-05test end-to-end/actions: Fix typo in TARGETS filePaul Cristian Sarbu
2025-06-05tutorial lint: Update example outputPaul Cristian Sarbu
2025-06-05Executor: Log action outputs sorted by pathPaul Cristian Sarbu
...also on failure or warning.
2025-06-05GitRepo: Fix wrong handling of fatal loggingPaul Cristian Sarbu
...in creating Git tree from filesystem directory.
2025-06-05GitRepo: Fix capitalisation inconsistency in loggingPaul Cristian Sarbu
2025-06-05GitRepo: Use std::invoke to call generic loggerPaul Cristian Sarbu
2025-06-05GitRepo: Reduce logging levelsPaul Cristian Sarbu
...in methods that should not report at error level themselves, but let this be handled by its callers. While there, remove an unneeded path manipulation in a defferent set of log messages.
2025-06-05GitRepo: Ensure compliance with existing noexcept specifiersPaul Cristian Sarbu
...while also removing some unneeded one. Do not implicitly trust that the third-party code called in these methods is non-throwing and instead properly handle any exception that might arise. Also remove the specifiers from some anonymous namespace methods where a try-catch would be overkill and let their callers handle any exceptions instead.
2025-06-05GitCAS: Reduce log level where fatal not expectedPaul Cristian Sarbu
...and fix inconsistent capitalisation.
2025-06-05GitCAS: Ensure compliance with existing noexcept specifiersPaul Cristian Sarbu
Do not implicitly trust that the third-party code called in these methods is non-throwing and instead properly handle any exception that might arise.
2025-06-05Update CHANGELOGKlaus Aehlig
2025-06-05man pages: extend "see also" sectionKlaus Aehlig
... to include at least all pages referenced throughout the man page.
2025-06-04test: Add check that TREE references reject upwards symlinksPaul Cristian Sarbu
2025-06-04directory_map: Correctly report fatal on failures to read from workspace rootsPaul Cristian Sarbu
2025-06-04Tests: Verify symlink handling in APIsOliver Reiche
... which should not do any symlink checks in compatible mode.
2025-06-04Remove unneeded extra checks for upwards symlinksPaul Cristian Sarbu
2025-06-04Executor: Check validity of action outputs in compatible modePaul Cristian Sarbu
This ensures that any entries that the standard remote execution protocol accepts but are invalid in justbuild, i.e., upwards symlinks, are rejected. For this purpose, do not fail in the action response instances, just perform the check there, as all required information is available, and set a flag that the executor can check as needed.
2025-06-04{Local,Bazel}Response: Fix logic for marking succesful populationPaul Cristian Sarbu
While in practice a failure to populate the fields of a response happens once per invocation, as it will trigger a failure of the execution, from an algorithmic standpoint the flag to mark a successful population of the response fields should only be set on actual success. Fix this.
2025-06-04Executor: Move noexcept enforcement to main public call pointsPaul Cristian Sarbu
...and remove specifiers from methods that might throw in unexpected ways. By doing this, balance the need to avoid wrongly silencing exception sources during execution with reducing the amount of try-catch blocks.
2025-06-04LocalCasReader: Add validity check for bazel directoriesPaul Cristian Sarbu
This will check if directories contain upwards symlinks.
2025-06-04Execution server: Let the underlying API handle invalid entriesPaul Cristian Sarbu
The execution server itself should not consider anything special in setting the response message to the client, instead let the underlying API fail or not during collection.