ImSejin/lezhin-comics-downloader

Error "Unable to detect element"

yimeji opened this issue · 8 comments

I got this error

org.openqa.selenium.StaleElementReferenceException: stale element reference: element is not attached to the page document
(Session info: headless chrome=96.0.4664.93)
For documentation on this error, please visit: https://www.seleniumhq.org/exceptions/stale_element_reference.html
Build info: version: 'unknown', revision: 'unknown', time: 'unknown'
System info: host: 'XXX', ip: 'XXX', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_311'
Driver info: org.openqa.selenium.chrome.ChromeDriver
Capabilities {acceptInsecureCerts: false, browserName: chrome, browserVersion: 96.0.4664.93, chrome: {chromedriverVersion: 96.0.4664.35 (8df3babf8da8f..., userDataDir: C:\Users\User\AppData\Local...}, goog:chromeOptions: {debuggerAddress: localhost:56714}, javascriptEnabled: true, networkConnectionEnabled: false, pageLoadStrategy: normal, platform: WINDOWS, platformName: WINDOWS, proxy: Proxy(), setWindowRect: true, strictFileInteractability: false, timeouts: {implicit: 0, pageLoad: 300000, script: 30000}, unhandledPromptBehavior: dismiss and notify, webauthn:extension:credBlob: true, webauthn:extension:largeBlob: true, webauthn:virtualAuthenticators: true}
Session ID: 70072de8a703deaba9563b9e6572b8dc
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at org.openqa.selenium.remote.http.W3CHttpResponseCodec.createException(W3CHttpResponseCodec.java:187)
at org.openqa.selenium.remote.http.W3CHttpResponseCodec.decode(W3CHttpResponseCodec.java:122)
at org.openqa.selenium.remote.http.W3CHttpResponseCodec.decode(W3CHttpResponseCodec.java:49)
at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:158)
at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(DriverCommandExecutor.java:83)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:552)
at org.openqa.selenium.remote.RemoteWebElement.execute(RemoteWebElement.java:285)
at org.openqa.selenium.remote.RemoteWebElement.isDisplayed(RemoteWebElement.java:326)
at org.openqa.selenium.support.ui.ExpectedConditions$9.apply(ExpectedConditions.java:274)
at org.openqa.selenium.support.ui.ExpectedConditions$9.apply(ExpectedConditions.java:270)
at org.openqa.selenium.support.ui.FluentWait.until(FluentWait.java:249)
at io.github.imsejin.lzcodl.core.Crawler.getNumOfImagesInEpisode(Crawler.java:183)
at io.github.imsejin.lzcodl.core.Downloader.downloadEpisode(Downloader.java:80)
at io.github.imsejin.lzcodl.core.Downloader.download(Downloader.java:69)
at io.github.imsejin.lzcodl.Application.main(Application.java:105)

Happen to some episodes from various series.

Hi @yimeji, Let me know command when the error happened.

Hi,

java -jar lezhin-comics-downloader-2.8.1.jar -l=en -n=thepalaceofbardo -r=7~7

That is paid episode.

Do you buy this?
The downloader can only do the episodes that your account can access to.

If you buy,
Run that command again with option -d and show me where browser is stucked.

For this particular episode this the error I got

     Exception occurs

java.nio.file.InvalidPathException: Illegal char < > at index 7: 0007 - Episode 7
at sun.nio.fs.WindowsPathParser.normalize(Unknown Source)
at sun.nio.fs.WindowsPathParser.parse(Unknown Source)
at sun.nio.fs.WindowsPathParser.parse(Unknown Source)
at sun.nio.fs.WindowsPath.parse(Unknown Source)
at sun.nio.fs.WindowsFileSystem.getPath(Unknown Source)
at sun.nio.fs.AbstractPath.resolve(Unknown Source)
at io.github.imsejin.lzcodl.core.Downloader.downloadEpisode(Downloader.java:87)
at io.github.imsejin.lzcodl.core.Downloader.download(Downloader.java:69)
at io.github.imsejin.lzcodl.Application.main(Application.java:105)

Can you answer my question?

Yes, I bought the episode.

The initial error message was from different series which I can't remember as I was downloading many episodes/series at the time. Those with error was extracted manually so I can't trace back which episode/series it was.

The command was from an episode that I purchased recently which gave the error that I posted after your reply.

-d command for n=thepalaceofbardo -r=7~7showed no issue on the browser. Able to login and open the episode just fine.

Sorry to slow response.
I tried to download ep.1 ~ 3 and it worked.

It is paid episodes from ep.4, so I can't download.

java.nio.file.InvalidPathException: Illegal char < > at index 7: 0007 - Episode 7

It says that the folder name contains blank characters, but it is difficult to understand.
I already created a folder with a similar name. (e.g. 0001 - Episode 1, 0002 - Episode 2, ...)

Without another clue, I can't help you anymore.

stale commented

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.