Open helcone opened 2 weeks ago
Fixed this by adding an equal sign to the if statement on line 262.
do {
const pageNav = await getPageNav()
if (pageNav?.page === undefined) {
break
}
if (pageNav.page >= totalContentPages) {
break
}
Added this and some other edits to this fork. Let me know if it works for you :)
Description:
The program encounters an error when taking screenshots on the last page (Page 248, Index 470) of a Kindle book. Instead of navigating to metadata creation, it becomes stuck, continually taking screenshots. The issue appears related to the inability to properly navigate past the last page.
Details:
Steps to Reproduce:
Expected Behavior: After reaching the last page, the program should proceed to metadata creation and gracefully exit without trying to navigate further.
Potential Cause: The issue may be caused by an unsuccessful attempt to click on a navigation element (.kr-chevron-container-right) on the last page, which might be unavailable or causing a context closure.
I am not really good at coding but this happened on both mac and linux as well I tried to use bith methods headless and with the GUI browser. Tell me how can I help to fix this.