Skip to content

feat(toolchain): pin the ESP-IDF v5.5.1 source tree as an fbuild package - #1978

Merged
zackees merged 1 commit into
mainfrom
agent/esp-idf-source-pin
Nov 10, 2026
Merged

zackees merged 1 commit into
mainfrom
agent/esp-idf-source-pin

Conversation

@zackees

@zackees zackees commented Nov 10, 2026

Copy link
Copy Markdown
Member

Follow-up to #1975/#1976 (part of #1970). The tool components are already merged; a delegated idf.py build (#1971) also needs to be an ESP-IDF checkout, and #1970's scope names "IDF source" as one of the pinned packages.

What this adds

crates/fbuild-toolchain/src/toolchain/esp_idf_source.rs: the pinned ESP-IDF v5.5.1 source tree as one fbuild package, installed with no git and no install.sh.

Why not the two "obvious" sources (measured 2026-11-09, v5.5.1 fcae3288)

Candidate Cost Verdict
esp-idf-v5.5.1.zip release asset 1,414 MB embeds .git/ (verified through the zip central directory, 32,664 entries) — not a package
recursive git clone --depth 1 + 23 submodule checkouts 603 MB on disk makes git a provisioning dependency
commit archive + 23 submodule archives (this PR) 61.1 MB + 47.0 MB download pinned by sha256, no git

The commit archive is the pinned commit's own tree, so it is the release rather than a summary of it: all 24 digests were re-downloaded and reproduced on the same day.

Measured

  • Installed tree: 449,952,002 B (du -sb, whole tree incl. all submodules) — recorded as IDF_SOURCE_EXTRACTED_BYTES.
  • Downloads: 61,134,823 B main + 46,969,524 B submodules = 108.1 MB (vs 603 MB for the clone).
  • A git-less tree is supported upstream: tools/cmake/version.cmake declares 5.5.1, version.txt is optional and idf_tools.py falls back to esp_idf_version.h.

Proof (real output)

Unit: soldr cargo test -p fbuild-toolchain --lib esp_idf_source → 7 passed; 0 failed; 1 ignored.

Ignored end-to-end (--ignored esp_idf_source_tree), really executed: 1 passed in 76.65 s — downloads 24 archives, verifies all 24 sha256s, extracts, populates all 23 submodules, asserts every .gitmodules path is non-empty, asserts version.cmake says 5.5.1/5/1, and a second ensure_normalized() is a no-op cache hit (#1970 AC4).

Gates: soldr clippy --workspace --all-targets -- -D warnings clean, soldr cargo fmt clean, boundary 44/43, check_test_layout.py ok, check_dylint_allowlists.py ok.

Not in this PR (deliberately)

The tool components merged in #1975/#1976 are only half of what a delegated
idf.py build needs; the subprocess also has to be an ESP-IDF checkout with
its 23 submodule contents. This installs the pinned commit's own archive plus
one sha256-pinned archive per gitlink through the existing SubmodulePlan, so
no git and no install.sh are involved.

Measured: 108.1 MB of downloads (61.1 main + 47.0 submodules) and a
449,952,002 B tree, versus 603 MB for a recursive shallow clone and 1,414 MB
for the release zip, which embeds .git/.
@coderabbitai

coderabbitai Bot commented Nov 10, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Triage

Development

Successfully merging this pull request may close these issues.

1 participant