Enforce dependency registry UTF-8 metadata#126
Conversation
There was a problem hiding this comment.
Claude Code Review
This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.
Tip: disable this comment in your organization's Code Review settings.
|
Caution Review failedPull request was closed or merged during review No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✅ Files skipped from review due to trivial changes (1)
📝 WalkthroughWalkthroughThis PR implements strict UTF-8 validation for DependencyRegistry dependency metadata. A new StreamMetadataRenderer.isValidUtf8() function validates UTF-8 sequences; DependencyRegistry enforces it on script chunks and provenance during writes, rejecting invalid sequences before storage while preserving size-check priority. Tests verify renderer validation, registry integration, and error-ordering semantics. StreamCore UTF-8 enforcement defers to issue ChangesDependency Registry UTF-8 Enforcement
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related issues
Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
Autonomous maintainer note before merge: CI is green, CodeRabbit posted its walkthrough and pre-merge checks with no actionable inline review threads, and no Claude review was triggered per user instruction. The CodeRabbit commit status still shows pending, but there are no bot findings to apply, so I am proceeding with merge under the documented autonomous run rules. |
Summary
StreamMetadataRendererDependencyRegistrywithDependencyFieldInvalidUTF8Part of #124. Core-level
StreamCoremetadata input enforcement remains split out under #125 because direct Core wiring exceeded the EIP-170 production size gate in local experiments.Validation
forge build --sizes --via-ir --skip test --skip script --forceforge fmt --check smart-contracts\DependencyRegistry.sol smart-contracts\StreamMetadataRenderer.sol test\StreamMetadataUtf8.t.solforge test --match-path test\StreamMetadataUtf8.t.sol -vvvforge test --match-path test\StreamDependencyRegistry.t.sol -vvvmake release-checksumsmake checkmake release-manifest-checkmake release-checksums-checkpowershell -NoProfile -ExecutionPolicy Bypass -File scripts\check.ps1git diff --checkbash -n scripts/check.shSize note
StreamCore: 24,135 runtime bytes, 441 bytes of EIP-170 headroomStreamCoreUTF-8 enforcement experiment: 25,755 runtime bytes, 1,179 bytes over EIP-170StreamCoreunchanged and enforces the policy for dependency registry production metadata writes onlySummary by CodeRabbit
New Features
Tests
Documentation
Chores