Skip to content

Mitigate upstream dependency failures (docx-rs, umya-spreadsheet)#89

Merged
developer0hye merged 2 commits intomainfrom
ralph/phase17-upstream-mitigations
Mar 1, 2026
Merged

Mitigate upstream dependency failures (docx-rs, umya-spreadsheet)#89
developer0hye merged 2 commits intomainfrom
ralph/phase17-upstream-mitigations

Conversation

@developer0hye
Copy link
Owner

Summary

  • Add upstream library names (docx-rs, umya-spreadsheet) to ConvertError::Parse messages so users can identify the source of parse failures
  • Enrich catch_unwind panic warnings with "upstream panic caught (docx-rs)" prefix and panic detail text
  • File upstream issues for both libraries with specific failure details and stack traces
  • Evaluate calamine as an alternative XLSX parser (17/22 failing fixtures pass, but lacks formatting support)

Changes

Code changes (US-330)

  • parser/docx.rs: Parse error message now includes (docx-rs) library name; panic-caught warnings include library name and panic detail
  • parser/xlsx.rs: Parse error messages now include (umya-spreadsheet) library name

Upstream tracking (US-331)

Research (US-332)

  • docs/xlsx-parser-evaluation.md: Comparison of calamine vs umya-spreadsheet
  • Recommendation: stay with umya-spreadsheet (calamine lacks cell formatting support needed for PDF fidelity)

Related: #83, #84

Test plan

  • cargo test -p office2pdf --lib — 703 tests pass
  • cargo test -p office2pdf --test docx_fixtures --test xlsx_fixtures --test pptx_fixtures — all fixture tests pass
  • cargo fmt --all -- --check — passes
  • cargo clippy --workspace -- -D warnings — passes
  • New tests verify error messages contain library names

🤖 Generated with Claude Code

developer0hye and others added 2 commits March 1, 2026 17:44
Add library identifiers (docx-rs, umya-spreadsheet) to ConvertError::Parse
messages so users can distinguish between upstream parse failures and our
own code errors. Also enrich the catch_unwind panic warning in the DOCX
parser to clearly indicate "upstream panic caught (docx-rs)" with panic
detail text.

Refs: #83, #84

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Yonghye Kwon <developer.0hye@gmail.com>
Evaluate calamine (v0.33.0) as a potential replacement for
umya-spreadsheet for XLSX parsing. Test results show calamine handles
17/22 of the failing fixtures, but it cannot extract cell formatting
(fonts, colors, borders), which is required for PDF conversion fidelity.

Recommendation: stay with umya-spreadsheet, monitor calamine for
formatting support, consider partial hybrid fallback in the future.

Refs: #83

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Yonghye Kwon <developer.0hye@gmail.com>
@developer0hye developer0hye force-pushed the ralph/phase17-upstream-mitigations branch from 4cc8d3a to 54ccb6c Compare March 1, 2026 08:45
@developer0hye developer0hye merged commit c0b20b0 into main Mar 1, 2026
14 checks passed
@developer0hye developer0hye deleted the ralph/phase17-upstream-mitigations branch March 1, 2026 08:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant