8000 fix(autoindex): tell .odp owners to save as .pptx, not export to PDF by thomas-villani · Pull Request #1131 · xerj-org/xerj · GitHub
[go: up one dir, main page]

Skip to content

fix(autoindex): tell .odp owners to save as .pptx, not export to PDF - #1131

Merged
xerj-org merged 1 commit into
xerj-org:mainfrom
thomas-villani:fix/odf-export-advice
Oct 5, 2026
Merged

xerj-org merged 1 commit into
xerj-org:mainfrom
thomas-villani:fix/odf-export-advice

Conversation

@thomas-villani
Copy link
Copy Markdown
Contributor

What this changes, and why

When autoindex finds an OpenDocument presentation (.odp), the unsupported-format hint tells the user to "export it as PDF". That was the best advice before #1117. Now that .pptx has its own extractor, saving as .pptx gives a better result: one record per slide with slide_title, table rows kept as rows, and speaker notes in the body. A PDF export keeps none of those. #1124 made the same update for .ods ("save it as .xlsx"), but the .odp arm was missed when PPTX landed.

The change is one line in sniff.rs (unsupported_document_advice("odp") now says "save it as .pptx"). The existing export-hint test now also checks the target format for ods and odp.

Evidence

Before the fix, the new assertion fails:

thread '...unsupported_documents_get_an_export_hint_not_archive_advice' panicked at crates/xerj-autoindex/src/sniff.rs:4127:9:
assertion failed: unsupported_document_advice("odp").unwrap().contains(".pptx")
test result: FAILED. 0 passed; 1 failed; ...

After the fix:

cargo test -p xerj-autoindex --lib   ->  test result: ok. 1189 passed; 0 failed; 2 ignored
cargo build --release -j 32 -p xerj-autoindex   ->  Finished `release` profile [optimized]

Checks

  • cargo fmt --all (--check clean)
  • Scoped release build: cargo build --release -j 32 -p xerj-autoindex
  • cargo test -p xerj-autoindex --lib passes
  • ES-YAML conformance suite: not run. This changes one user-facing hint string in autoindex's sniffer, which is a client-side crate. No engine or wire behavior changes.
  • New ES-compatible YAML case: N/A
  • Docs: no doc quotes the .odp hint (searched the repo).
  • CONTRIBUTION_REVIEW audit: N/A, a one-line message change.

Not run: clippy -D warnings (CI runs it) and the ES-YAML gate, for the reason above.

Provenance

  • Written by: AI agent (Claude Code, Claude Opus 5.5), run by @thomas-villani, who reviewed it.
  • Verified: every output above. Tests ran in a rust:latest container with the full repo mounted, because the crate's tests don't compile on Windows.
  • Assumed: that LibreOffice/Keynote "Save as .pptx" output is extracted as well as PowerPoint's own files. feat(autoindex): extract PowerPoint decks (.pptx), one record per slide #1117 was tested on python-pptx-generated decks, not on LibreOffice exports.

🤖 Generated with Claude Code

Motivation: the unsupported-format hint for an OpenDocument presentation
still said "export it as PDF". That was the best advice before xerj-org#1117; since
.pptx has its own extractor, it is the better target: one record per slide
with `slide_title`, table rows kept as rows, and speaker notes in the body,
none of which survives a PDF export. xerj-org#1124 made the same update for .ods
("save it as .xlsx"); the .odp arm was missed when PPTX landed.

Change: sniff.rs `unsupported_document_advice("odp")` -> "save it as .pptx".
The existing export-hint test now also pins the target format for ods and
odp.

Evidence:
- New assertion failed before the fix:
  `assertion failed: unsupported_document_advice("odp").unwrap().contains(".pptx")`
- After: `cargo test -p xerj-autoindex --lib` -> 1189 passed, 0 failed,
  2 ignored (rust:latest container, full repo mounted).
- `cargo fmt --all -- --check` clean.

Written by an AI agent (Claude Code) on behalf of the PR author.
@cla-bot cla-bot Bot added the cla-signed label Oct 4, 2026
@xerj-org
xerj-org merged commit c90383b into xerj-org:main Oct 5, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

0