skyvern icon indicating copy to clipboard operation
skyvern copied to clipboard

fix scrolling problem

Open LawyZheng opened this issue 1 year ago • 9 comments

LawyZheng avatar May 09 '24 11:05 LawyZheng

IMO using behavior:instant everywhere would probably trigger a lot more captcha/bot detectors.

OB42 avatar May 09 '24 17:05 OB42

IMO using behavior:instant everywhere would probably trigger a lot more captcha/bot detectors.

Good idea. but it's more important to take screenshots than worrying about the bot-detection problem.

LawyZheng avatar May 09 '24 17:05 LawyZheng

IMO using behavior:instant everywhere would probably trigger a lot more captcha/bot detectors.

Good idea. but it's more important to take screenshots than worrying about the bot-detection problem.

how is scrolling related to screenshots exactly?

OB42 avatar May 09 '24 19:05 OB42

@OB42 For a long page, Skyvern does multiple scrolls until the end of the page, to generate multiple screenshots and send those to LLM together. We've tested this heavily earlier which drove us to this solution: Skyvern performs better with multiple screenshots compared to sending one big whole page screenshot - we believe it has to do with the resolution of the screenshots. Playwright's whole page screenshot resolution is not so good

Most of the websites have default auto behavior which jumps instantly when using scrollBy. We haven't seen any bot detection issues so far. Pls let us know if you find a bot detection example and we can probably help figure out a solution.

wintonzheng avatar May 10 '24 02:05 wintonzheng

@LawyZheng The scrollUpAndDown and scrollDownAndUp can be removed. It was there to counter the weird select-2 behavior which has been fixed now

wintonzheng avatar May 10 '24 02:05 wintonzheng

@LawyZheng after removing scroll up and down, we might not need the behavior: instant. Can you test that?

wintonzheng avatar May 10 '24 02:05 wintonzheng

@LawyZheng after removing scroll up and down, we might not need the behavior: instant. Can you test that?

sure. I will test some cases to see if it still works well without behavior: instant

LawyZheng avatar May 10 '24 02:05 LawyZheng

@LawyZheng after removing scroll up and down, we might not need the behavior: instant. Can you test that?

The result is negative. Still can't do scrolling if scrollUpAndDown has been removed.

LawyZheng avatar May 10 '24 03:05 LawyZheng

@LawyZheng PR looks good

wintonzheng avatar May 10 '24 03:05 wintonzheng