Git Product home page Git Product logo

Comments (15)

spolu avatar spolu commented on August 16, 2024

Yeah this one is annoying as it is handled as a run error and the whole run is interrupted preventing the rest of inputs to complete.

We can extract that error and return a JSON to represent it. That means apps would have to gracefully handle that state which requires more logic.

from dust.

tmontana avatar tmontana commented on August 16, 2024

Any way to adjust timeout length?

from dust.

spolu avatar spolu commented on August 16, 2024

I think these pages are just going to timeout whatever value you put. But to answer your question, not at the time, need to add that as a parameter to the browserless block.

from dust.

spolu avatar spolu commented on August 16, 2024

30s is already... a lot.

from dust.

aickin avatar aickin commented on August 16, 2024

Worth noting that it's 30s not just for downloading the page, but for downloading all the scripts, images, etc., and running all the JavaScript until the page settles down. I also suspect but am not sure that:

  • Browserless uses pretty underpowered machines
  • The browsers start with nothing in cache
  • Low usage accounts may have low numbers of simultaneous browsers spun up until they hit timeouts

from dust.

spolu avatar spolu commented on August 16, 2024

Agreed. But some pages just fail repetitively and consistently. The first fix is really to return errors as a result instead of interrupting the run I think?

from dust.

tmontana avatar tmontana commented on August 16, 2024

I can confirm there is something badly implemented here. I ran my own code in python using browserless API as a test and never getting any errors from default parameters.

from dust.

spolu avatar spolu commented on August 16, 2024

Nice. Can you share some urls where you see discrepancies ?

from dust.

tmontana avatar tmontana commented on August 16, 2024

image

https://www.cnn.com/2020/02/21/business/wells-fargo-settlement-doj-sec/index.html

https://www.forbes.com/sites/eriksherman/2021/09/28/wells-fargo-gets-into-trouble-yet-again-over-alleged-fraud/

from dust.

tmontana avatar tmontana commented on August 16, 2024

This happens a lot

image

from dust.

spolu avatar spolu commented on August 16, 2024

Yes I had the same issue on CNN. Will investigate 👍

from dust.

spolu avatar spolu commented on August 16, 2024

Added 16s timeout instead of 30s and the networkidle2 option, should solve most issues, let me know if that's not the case 👍

from dust.

bcjordan avatar bcjordan commented on August 16, 2024

I still have this error for many webpages, is there any way to code around a solution to allow it to allow failures or have them null in the results array? In instances where you're navigating to multiple search result pages to parse there's still good data in the other pages

from dust.

spolu avatar spolu commented on August 16, 2024

@bcjordan we've added a configuration flag (only available behind API at this stage) to have the browser block return an error object instaed of erroring the run[0]:

You need to pass in your API call: config: { "BROWSER_BLOCK_NAME": { "error_as_output": true } }

[0] https://github.com/dust-tt/dust/blob/main/core/src/blocks/browser.rs#L91-L100

from dust.

bcjordan avatar bcjordan commented on August 16, 2024

@spolu oh that's perfect, thanks so much!

from dust.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.