feat(email): resolve local inline media evidence - #1351
Conversation
|
Warning Review limit reached
Next review available in: 22 minutes Limit details: You’ve used all 1 included review currently available under your plan. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (5)
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 |
|
PR governance metadata gate is not ready for
|
|
@opencode-agent review current exact head |
|
Closing as technically superseded by #1376, with unique work preserved. Fresh exact-head comparison proves current #1351 head |
Scope
Implement the bounded deterministic media-normalization slice from #1350 before any OCR/vision/LLM stage:
cid:references to image body parts inside the nearestmultipart/relatedscope;data:images locally;TDD and implementation evidence
The branch began with a deliberately RED acceptance-test commit before the production resolver existed. Production code and later aggregate-bound hardening were implemented on the same branch with regression tests first.
A current-head review found a second-order safety defect in digest deduplication: when identical bytes appeared once under a valid media type and once under a mismatched declaration,
_store_artifact()returned whichever artifact representation was encountered first. That could upgrade the mismatched MIME/CID occurrence tollm_safe, or downgrade a valid occurrence, solely because of traversal order.0636a572f17319794e5cf3c909711d35f336b01aadds both traversal orders for one PNG payload declared asimage/pngandimage/jpeg.a9258a4be9e09e9b4aa78ef57140996669905e73separates occurrence-scoped validation from the canonical digest artifact and promotes a canonical artifact only when a genuinely safe occurrence exists.f49b6302a41d479a1d49a52f761e7988d8359838records that content-addressing is not safety authority.The resulting contract keeps one safe canonical PNG artifact while the mismatched MIME and CID occurrences remain
unsafe_media, independent of traversal order.Standards and safety boundary
Primary standards are RFC 2045/2046 MIME, RFC 2183 Content-Disposition, RFC 2387
multipart/related, RFC 2392cid:URLs, and RFC 2397data:URLs. The APA 7 trace and shipped-state boundary are recorded indocs/doctoring/email-inline-media-resolution.md.This resolver never fetches remote image URLs.
llm_safemeans only bounded admitted media with a matching deterministic signature; downstream decoders/model adapters still own actual decode and model-specific validation. Semantic labels such as logos, signatures, screenshots, charts, scans, and tables remain out of this deterministic slice.Current-base reconciliation
The predecessor exact head was reconstructed onto protected
develop@bc98789521d21271e84789888413c182aa111b4dby a normal non-forced merge. The protected-base delta was disjoint from the four media-resolution paths, so current protecteddevelopis preserved everywhere outside this bounded slice.Exact candidate
develop@bc98789521d21271e84789888413c182aa111b4dcdaf876f1e81d723efe2771fcf1f00a20fda6fd3Merge boundary
Do not merge until the unchanged exact head satisfies every live required CI/security/coverage gate, all actionable current-head threads are resolved, a qualifying independent non-author current-head approval exists, and live protected-branch/ruleset policy accepts the merge without bypass. Queued, stale, predecessor-head, skipped-required, neutral, rate-limited, status-only, author-only, or model-only evidence is not success.
Refs #1350