Pool-Of-Tears / Myne

An android app to download & read ebooks from Project Gutenberg, built with Jetpack Compose.
https://pooloftears.in
Apache License 2.0
1.14k stars 65 forks source link

Error opening imported title #234

Open tjsuominen opened 2 weeks ago

tjsuominen commented 2 weeks ago

Steps to reproduce

  1. Imported ePub title (Windows 11 guide) with success
  2. When trying to open it, get error

Expected behaviour

Title opened

Actual behaviour

Build version: 4.3.0 Current date: 2024-10-28 20:32:14 Device: Google Pixel Tablet OS version: Android 15 (SDK 35)

Stack trace:
java.lang.OutOfMemoryError: Failed to allocate a 134217744 byte allocation with 55289600 free bytes and 52MB until OOM, target footprint 268435456, growth limit 268435456 at C6.b.b(Unknown Source:15) at A.w.W(Unknown Source:21) at C6.e.L0(Unknown Source:50) at C6.p.a(Unknown Source:12) at S3.h.a(Unknown Source:27) at C6.p.D0(Unknown Source:151) at C6.p.l(Unknown Source:66) at x6.n.a(Unknown Source:29) at C6.p.D0(Unknown Source:151) at C6.p.l(Unknown Source:66) at S3.b.a(Unknown Source:88) at C6.p.D0(Unknown Source:151) at Q3.j.t(Unknown Source:397) at Q3.j.k(Unknown Source:12) at Z2.d.a0(Unknown Source:4) at k6.y.A(Unknown Source:73) at h4.h.t(Unknown Source:217) at D4.a.i(Unknown Source:8) at k6.E.run(Unknown Source:112) at h3.b.run(Unknown Source:114) at r6.i.run(Unknown Source:2) at r6.a.run(Unknown Source:91) Suppressed: p6.g: [B{Cancelling}@98cb8d8, Dispatchers.IO]

Device name

Pixel Tablet

Android version

Android 15

Myne version

4.3.0

Device logs

No response

Additional information

No response

starry-shivam commented 2 weeks ago

I'll take a look, a bit busy recently. Thanks for reporting.

Edit: Could you please provide the link to the EPUB file you were trying to import? It will help me reproduce the issue.

tjsuominen commented 2 weeks ago

Here's the link

I'll remove file in the next 24 hrs

tjsuominen commented 6 days ago

Any news, did you identify the issue?

starry-shivam commented 6 days ago

Any news, did you identify the issue?

Yes, apparently the book is very large and contains images and other content, so parsing the entire book at once (as it does currently) causes it to hit the memory limit enforced by the system, leading to an OOM error. I’ve been a bit busy recently due to some real-life matters, so I haven't had much time to work on my projects. I'll try to fix this issue as soon as I can. Thanks for understanding! :)

tjsuominen commented 4 days ago

Appreciated, thx. Take your time.