Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scroll to last on slower connections #33

Open
HuwSy opened this issue Feb 21, 2021 · 2 comments
Open

Scroll to last on slower connections #33

HuwSy opened this issue Feb 21, 2021 · 2 comments

Comments

@HuwSy
Copy link

HuwSy commented Feb 21, 2021

The navToEnd function on slower internet connections does not achieve the expected because the unloaded images gray boxes makes the process think it has reached the end as there are identical screen shots. Updating line 362 as follows resolves this issue without impacting the process too much.

time.Sleep(10 * tick)

@jacobwhall
Copy link

I like the simplicity of your solution, but would want to be more sure the program doesn't skip any of my images. Maybe this is related to #26?

@HuwSy
Copy link
Author

HuwSy commented Mar 2, 2021

Also related to slow connections and simple solution to these. The left button and related keyboard shortcut doesn't always load if the image/video takes to long to load which then breaks navLeft function. Even rerunning the script fails as it loads the same image and it is still a big picture and doesn't load in a timely manner. After resizing accidentally I noticed the button appear. So locally I have changed this function to begin;

func navLeft(ctx context.Context) error {
var res []string
chromedp.EvaluateAsDevTools(window.resize();, &res)
time.Sleep(tick)

Which seems to do the trick without overcomplicating anything.

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

No branches or pull requests

2 participants