feat(ci): reusable setup composite action with fbuild-hash pinning (closes #101)#110
feat(ci): reusable setup composite action with fbuild-hash pinning (closes #101)#110
Conversation
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 50 minutes and 25 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughThis PR introduces a GitHub composite action for setting up fbuild-based CI workflows, complete with documentation. The action installs fbuild via pip, computes a deterministic content hash from the installed distribution's metadata, manages a cache directory, and integrates with Changes
Sequence DiagramsequenceDiagram
participant Step as Workflow Step
participant Action as Setup Action
participant PIP as pip/PyPI
participant Cache as actions/cache@v4
participant Env as Environment
Step->>Action: Trigger composite action
Action->>PIP: Install fbuild (version/latest)
PIP-->>Action: fbuild installed
Action->>Action: Compute content hash from dist-info RECORD
Action->>Action: Resolve cache directory path
Action->>Cache: Restore cache using key (OS + arch + hash + extras)
Cache-->>Action: Return cache-hit status
Action->>Env: Export FBUILD_CACHE_DIR
Action-->>Step: Return outputs (cache-hit, cache-dir, fbuild-hash)
Estimated Code Review Effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly Related Issues
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
c45e8f3 to
4e0a51c
Compare
The composite setup action now computes sha256 of the installed fbuild wheel's dist-info RECORD file and bakes it into the cache key. This protects against silent cache poisoning when fbuild is re-released at the same PyPI version or installed from a non-registry source. - action.yml: new "Resolve fbuild content hash" step; output fbuild-hash - README.md: document the new output and why hash-pinning matters - docs/CI_CACHING.md: promote fbuild-hash from optional to required; provide a raw-snippet example for consumers not using the action - tasks/todo.md: mark the follow-up item done-as-of-this-commit Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
4e0a51c to
844c4fa
Compare
Summary
FastLED/fbuild/.github/actions/setupcomposite action for one-line fbuild CI setup (install + cache + env wiring).RECORD), not just the PyPI version string — protects against silent cache poisoning from re-released wheels or non-registry installs.docs/CI_CACHING.mdto promote fbuild-hash from optional to required, with a raw-snippet example for consumers who don't want the action dependency.Why hash-pinning matters
The fbuild cache stores toolchains, frameworks, and build outputs whose layout is tied to fbuild's fingerprint format, response-file generation, and embedded paths. A version string does not discriminate against re-released wheels, dev builds, or different platform tags — any of which can poison a restored cache. Hashing the installed
RECORDcovers all of those cases and makesfbuild-version: latestsafe-by-construction.Test plan
ubuntu-latest,macos-latest,windows-latest.github/actions/setup/README.md)fbuild-hashoutput for their own diagnostics🤖 Generated with Claude Code
Summary by CodeRabbit
New Features
Documentation
Chores