Skip to content

feat(prebuilt): stamp the arduino-esp32 core component identity in staging (#1882) - #2162

Merged
zackees merged 2 commits into
mainfrom
agent/prebuilt-core-component-stamp
Nov 23, 2026
Merged

zackees merged 2 commits into
mainfrom
agent/prebuilt-core-component-stamp

Conversation

@zackees

@zackees zackees commented Nov 23, 2026 •

Copy link
Copy Markdown
Member

feat(prebuilt): stamp the core component's identity in staging (#1882)

Decision 8a of docs/design/artifact-serving-decisions.md: framework identity
is per component and is taken in that component's staging directory, never as
a hash of an installed tree. This lands the first component and the machinery
every other component reuses.

  • component_id: content id over one component's files (relative path, bytes,
    exec bit, symlink target), with component-root-relative subtrees excluded;
    stamp read/write (component-identity.json, schema 1, recipe counter).
    A tree with no stamp, an unreadable stamp, or a foreign schema has no
    identity, and read_stamp says so instead of guessing.
  • Esp32Framework: the core component is stamped in staging, after every
    staging mutation and before the atomic rename, excluding
    tools/esp32-arduino-libs and tools/.libs-archives - the subtrees the SDK/MCU
    merge writes into after the core install commits, so SDK patching cannot
    move the core identity. CORE_RECIPE is 0 because no post-extract mutation of
    the core's own subtree runs on main today; adding one means bumping it.
  • The stamp file and the install sentinel are excluded from the id, so the id
    taken in staging equals the id of the installed tree it became.

Verified (real output): soldr cargo test -p fbuild-packages-fetch --lib 299
passed / 0 failed / 2 ignored (15 new); -p fbuild-library --lib 383 passed /
0 failed / 9 ignored (1 new); clippy on both crates with --all-targets
-D warnings exit 0; fmt check exit 0; platform boundary rows=0 and
ci.test_enforce_platform_boundary 14 tests OK.

Not done here: nothing consumes the stamp yet (no fingerprint, no planner, no
ladder), and the closure wiring is proven at function level only - a real
ensure_installed install is the true proof and needs a full framework download,
which belongs with the ignored e2e cells of #2133. Per decision 8c nothing is
published without explicit maintainer approval.

#1882 stays open (remaining units: SDK/MCU component stamps, patch-sites moved
ahead of the stamp, the hidden --prebuilt-core opt-in, the 8b ladder).

Dylint follow-up (commit 1a241cd): ban_manual_slash_normalize rejected the
hand-rolled replace('\\', "/") helper, the only real red check on the first
push (local clippy cannot see that lint). Exclusion names and symlink targets now
go through NormalizedPath::new(..).display_slash(), which also strips Windows
extended-length prefixes; the redundant re-normalization in relative_key is
gone. Re-verified: packages-fetch 299 passed / 0 failed / 2 ignored, clippy
-p fbuild-packages-fetch --all-targets -D warnings exit 0, fmt exit 0,
boundary rows=0 + 14 boundary unittests OK, and Dylint Full green on CI.

Decision 8a of docs/design/artifact-serving-decisions.md: framework identity
is per component and is taken in that component's staging directory, never as
a hash of an installed tree. This lands the first component and the machinery
every other component reuses.

- component_id: content id over one component's files (relative path, bytes,
  exec bit, symlink target), with component-root-relative subtrees excluded;
  stamp read/write (`component-identity.json`, schema 1, `recipe` counter).
  A tree with no stamp, an unreadable stamp, or a foreign schema has no
  identity, and read_stamp says so instead of guessing.
- Esp32Framework: the core component is stamped in staging, after every
  staging mutation and before the atomic rename, excluding
  tools/esp32-arduino-libs and tools/.libs-archives - the subtrees the SDK/MCU
  merge writes into after the core install commits, so SDK patching cannot
  move the core identity. CORE_RECIPE is 0 because no post-extract mutation of
  the core's own subtree runs on main today; adding one means bumping it.
- The stamp file and the install sentinel are excluded from the id, so the id
  taken in staging equals the id of the installed tree it became.

Verified (real output): `soldr cargo test -p fbuild-packages-fetch --lib` 299
passed / 0 failed / 2 ignored (15 new); `-p fbuild-library --lib` 383 passed /
0 failed / 9 ignored (1 new); clippy on both crates with --all-targets
-D warnings exit 0; fmt check exit 0; platform boundary rows=0 and
ci.test_enforce_platform_boundary 14 tests OK.

Not done here: nothing consumes the stamp yet (no fingerprint, no planner, no
ladder), and the closure wiring is proven at function level only - a real
ensure_installed install is the true proof and needs a full framework download,
which belongs with the ignored e2e cells of #2133. Per decision 8c nothing is
published without explicit maintainer approval.

#1882 stays open (remaining units: SDK/MCU component stamps, patch-sites moved
ahead of the stamp, the hidden --prebuilt-core opt-in, the 8b ladder).
@coderabbitai

coderabbitai Bot commented Nov 23, 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

Note

.coderabbit.yaml has unrecognized properties

CodeRabbit is using all valid settings from your configuration. Unrecognized properties (listed below) have been ignored and may indicate typos or deprecated fields that can be removed.

Parsing warnings: 1

Validation error: Unrecognized key: "enabled" at "reviews.pre_merge_checks"
Configuration instructions

  • Please see the configuration documentation for more information.
  • You can also validate your configuration using the online YAML validator.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json
  • 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

Dylint's ban_manual_slash_normalize rejected the hand-rolled
`value.replace('\\', "/")` helper in component_id.rs, which was the only
real failure on PR #2162 (the rest were cascade + the missing CI summary).

- exclusion names and symlink targets now go through
  NormalizedPath::new(..).display_slash(), which also strips Windows
  extended-length prefixes (\\?\ / \\?\UNC\) the hand-rolled version kept.
- relative_key drops the redundant re-normalization; NormalizedPath already
  renders slash-separated, so a literal backslash in a Linux file name is no
  longer silently folded into a separator.
- delete slash_key entirely.
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