Skip to content

Integrate all reader formats and asynchronous book hashing - #141

Merged
Eoic merged 1 commit into
developmentfrom
feature/140-reader-formats-integration
Nov 9, 2026
Merged

Eoic merged 1 commit into
developmentfrom
feature/140-reader-formats-integration

Conversation

@Eoic

@Eoic Eoic commented Nov 8, 2026 •

Copy link
Copy Markdown
Member

Connects all seven supported formats—EPUB, PDF, MOBI, AZW3, TXT, CBR and CBZ—to the client reader and import flows. File-integrity hashing now runs asynchronously, and Back remains available while the book's media loads.

Closes #140. Covers the client integration portion of FR-3_1.

Depends on reader PR #25; merge the reader PR first. Both app/pubspec.yaml and app/pubspec.lock pin reader commit b4aafafcb4d80afe5f140960ac91dcc251dac70e. The lockfile also resolves its nested Kindle decoder from that same Git revision. No local path override is committed.

Changes

  • Route the added formats through the adapter and preserve their original-format locators.
  • Accept all seven formats in native/web import. New web formats store original bytes in OPFS with filename-based title and Unknown Author metadata until richer extraction is available.
  • Use an isolate for native SHA-256 and asynchronous WebCrypto on the web; await integrity checks before using or caching bytes.
  • Keep Back available during media loading and ignore late completion after leaving the page.
  • Add adapter, media-integrity, import-worker and navigation regression coverage.

The reader's PDF conversion dependency requires archive 4.0.9 and image 4.9.2 in the resolved lockfile; those downgrades are intentional compatibility constraints, not unrelated package maintenance.

Validation

  • With the local reader override disabled, flutter pub get --enforce-lockfile passes without modifying the manifest or lockfile. Client formatting, analyzer and all 22 JavaScript worker/bootstrap tests pass.
  • Full client suite against the exact committed reader pin: 2,284 passed, 19 skipped. Release web build passed against that same Git dependency.
  • Earlier source validation passed the macOS debug build, Chrome media/hash tests, and focused ReaderPage tests.
  • Actual client import/open/navigation checks passed for a 140 MB scanned PDF, 240 MB comic CBZ and 29 MB TXT in an isolated guest browser profile. PDF reopening and navigation reached a readable title page; document readiness is not equivalent to first rasterized paint.

Limits

Reader PR #25 records the complete seven-format stress observations. Huge MOBI/AZW3 files still show main-thread handoff stalls, legacy MOBI opens slowly, and whole-comic conversion has high peak memory. This PR does not establish uniformly non-blocking large-book behavior or NFR-4_2 acceptance.

Physical Android/iOS, low-memory devices and server upload/sync were not tested. The client debug stress session also logged two SQLite worker protocol errors (installBroadcastUpdates) and route-semantics warnings; the final three import/read flows completed without additional scoped errors. That session is not an error-free runtime certification, and the SQLite mismatch remains uninvestigated.

Downloaded large books, generated stress archives and local result screenshots are excluded from Git.

Closes #140. Pin reader b4aafaf and preserve original-format locations across import and reading.
Copilot AI balanced review requested due to automatic review settings November 8, 2026 01:48

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 8, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-08T01:49:52.693402Z 661c8fd PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@codecov

codecov Bot commented Nov 8, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@Eoic
Eoic merged commit 081d116 into development Nov 9, 2026
10 checks passed
@Eoic
Eoic deleted the feature/140-reader-formats-integration branch November 9, 2026 21:16
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.

Integrate all seven reader formats and asynchronous book hashing

2 participants