Open tommy-anderson opened 2 months ago
Hello @tommy-anderson, yeah it would definitely be a good improvement. What we would do is another function to get some debug information: "what caused waitForStability
" to not wait. So we could call this function in the error message to get debug information. What do you think?
Sure that could work !
Bug description
Argos has some internal stabilizers
sometimes when taking screenshots they fail, and It's very hard to troubleshoot what happened.
Correct behavior expected
I want to see for that img src=X has not loaded, or that there are 2 elements with aria-busy currently on page.
Wrong behavior observed
Logs are not useful, and need to actually go into node_modules and add console messages to debug.
Reproduce
Have a image with a bad src in the page you're trying to screenshot. And screenshot it.
Notes
I wanted to open a PR where I would just add the
errorMsg
property to thewaitUntil
call, but since you currently have everything in a single functionwaitForStability
the change would involve modifying the way stabilization is done, and would be too opinionated.