Skip to content

ci: dependency steps use bootstrap script#1168

Merged
alandefreitas merged 2 commits intocppalliance:developfrom
alandefreitas:develop
Mar 19, 2026
Merged

ci: dependency steps use bootstrap script#1168
alandefreitas merged 2 commits intocppalliance:developfrom
alandefreitas:develop

Conversation

@alandefreitas
Copy link
Collaborator

CI now uses the bootstrap script to install all dependencies instead of doing it inline. The script writes dependency paths and compiler flags to an env file that the build step picks up.

The documentation included 5 different methods for installing MrDocs from source, tvery developer had their own way of setting up MrDocs locally, and the CI workflow had its own completely separate procedure. When one changed, the other drifted. New contributors would follow the docs, hit errors, and waste hours figuring out what the CI did differently. The CI workflow itself was over 1300 lines of bash, YAML, and Handlebars templates that very few people understood.

Now there's one way to set up dependencies: python bootstrap.py. It works the same on a developer's laptop and in CI. If a dependency version changes, it changes in one place. If a build flag is wrong, it's fixed in one place. New contributors clone the repo, run the script, and get the same environment CI uses on their platform.

Bootstrap handles all dependency installation in CI via --cache-dir and --env-file, which were the two new features we implemented so that the bootstrap script interacts properly with CI cache. libc++ runtimes are always built automatically for clang sanitizer configurations. The LLVM recipe now includes the correct build options (Ninja, tablegen, tools off). CI uses devcontainer images where possible, removing setup steps for cmake, ninja, and system packages. install.adoc now documents bootstrap as the primary build path.

Also fixed recipe install paths, Windows preset suffix, build_dir template, and MSan cache key. Added --cache-dir, --env-file, --cflags/--cxxflags/--ldflags, prerequisite detection, and 316 bootstrap unit tests. Most "new" code in this PR is the bootstrap script being modularized and tested, which git will consider new lines of code. Most code removed came from the old ci.yml script.

@github-actions
Copy link

github-actions bot commented Mar 18, 2026

🚧 Danger.js checks for MrDocs are experimental; expect some rough edges while we tune the rules.

⚠️ Warnings

Warning

Source changed but no tests or fixtures were updated.

🧾 Changes by Scope

Scope Lines Δ Lines + Lines - Files Δ Files + Files ~ Files ↔ Files -
🏗️ Build / Toolchain 10538 10198 340 45 17 28 - -
⚙️ CI 777 311 466 6 - 6 - -
📄 Docs 329 38 291 1 - 1 - -
📦 Other 77 36 41 2 1 1 - -
🛠️ Source 22 13 9 1 - 1 - -
🤝 Third-party 8 7 1 2 - 2 - -
Total 11751 10603 1148 57 18 39 - -

Legend: Files + (added), Files ~ (modified), Files ↔ (renamed), Files - (removed)

🔝 Top Files

  • util/bootstrap/tests/test_dry_run.py (Build / Toolchain): 1226 lines Δ (+1226 / -0)
  • util/bootstrap/tests/test_ide_configs.py (Build / Toolchain): 893 lines Δ (+893 / -0)
  • util/bootstrap/tests/test_installer.py (Build / Toolchain): 812 lines Δ (+812 / -0)

Generated by 🚫 dangerJS against 1de676d

@alandefreitas alandefreitas changed the title ci: CI dependency steps use bootstrap script ci: dependency steps use bootstrap script Mar 18, 2026
@cppalliance-bot
Copy link

cppalliance-bot commented Mar 18, 2026

An automated preview of the documentation is available at https://1168.mrdocs.prtest2.cppalliance.org/index.html

If more commits are pushed to the pull request, the docs will rebuild at the same URL.

2026-03-19 16:22:29 UTC

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 80441d6904

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@codecov
Copy link

codecov bot commented Mar 18, 2026

Codecov Report

❌ Patch coverage is 83.06233% with 125 lines in your changes missing coverage. Please review.
✅ Project coverage is 77.85%. Comparing base (0a69301) to head (1de676d).
⚠️ Report is 2 commits behind head on develop.

Files with missing lines Patch % Lines
util/bootstrap/src/installer.py 74.57% 38 Missing and 7 partials ⚠️
util/bootstrap/src/tools/prerequisites.py 73.57% 26 Missing and 11 partials ⚠️
util/bootstrap/src/recipes/builder.py 84.81% 7 Missing and 5 partials ⚠️
util/bootstrap/src/configs/vscode.py 71.05% 6 Missing and 5 partials ⚠️
util/bootstrap/src/configs/pretty_printers.py 65.21% 4 Missing and 4 partials ⚠️
util/bootstrap/src/presets/generator.py 86.20% 2 Missing and 2 partials ⚠️
util/bootstrap/src/recipes/cache_keys.py 92.50% 1 Missing and 2 partials ⚠️
util/bootstrap/src/recipes/fetcher.py 92.59% 1 Missing and 1 partial ⚠️
util/bootstrap/src/core/filesystem.py 90.90% 0 Missing and 1 partial ⚠️
util/bootstrap/src/core/prompts.py 93.33% 0 Missing and 1 partial ⚠️
... and 1 more
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1168      +/-   ##
===========================================
+ Coverage    77.44%   77.85%   +0.40%     
===========================================
  Files          313      346      +33     
  Lines        29475    32459    +2984     
  Branches      5880     6571     +691     
===========================================
+ Hits         22827    25271    +2444     
- Misses        4403     4776     +373     
- Partials      2245     2412     +167     
Flag Coverage Δ
bootstrap 81.89% <82.99%> (?)
cpp 77.44% <100.00%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

jerry_port_context_free was declared with the wrong signature
(void*, jerry_size_t) instead of JerryScript's actual API (void).
When jerry_cleanup() called it with no arguments, the function
read garbage from registers as the pointer to free. Also removed
a redundant explicit call after jerry_cleanup() that was a
double-free.

Silent on most compilers but GCC 15 on aarch64 put different
values in those registers, making the corruption visible.
@alandefreitas alandefreitas force-pushed the develop branch 8 times, most recently from 511ce21 to 164fb25 Compare March 19, 2026 04:22
CI uses the bootstrap script to install all dependencies instead
of doing it inline. The script writes dependency paths and compiler flags to an env file that the build step picks up.
@alandefreitas alandefreitas merged commit 9b4fafb into cppalliance:develop Mar 19, 2026
33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants