[Python] Python Pyppeteer vs Python Selenium for RPA (Robotic Process Automation) [closed]

Discussão em 'Python' iniciado por Stack, Junho 9, 2025.

  1. Stack

    Stack Membro Participativo

    I just want the opinion of someone who does RPA regularly. Do you think Pyppeteer or Selenium (with Python) is better for robotic process automation? First, let me explain my situation.

    In our company, we want RPA tools that we can build in Python. We don’t want to use UiPath because we’ve found that a general-purpose programming language like Python can cover all our needs. We use our robots to enter information into an electronic medical records platform that lacks API write functions.

    When we use Selenium, our chromedriver.exe version automatically upgrades to match the version of the Chrome browser we have. We cannot restrict this policy. Based on our cybersecurity team’s requirements, we are not allowed to use outdated versions of Chrome. As a result, our chromedriver.exe automatically upgrades and changes from week to week. Because of subtle differences in each update, we get unpredictable results with our code. Code that works fine one week can fail the next week after a browser update.

    We know that a possible solution would be to containerize the project files, drivers, and browser versions. But this is too much trouble because our VMs are Windows-based, and tools like Docker are not very reliable on Windows. It would help if we had Linux VMs, but that’s not an option for us at the moment.

    Management has been leaning toward using Pyppeteer, the Python port of Puppeteer. Pyppeteer is supposed to be less resource-intensive. However, in our own testing, 8 instances of a Selenium bot use FAR fewer resources than a single Pyppeteer bot.

    The advantage of Pyppeteer is this: it can run asynchronously (which is nice, although we can always run multiple synchronous instances of Selenium). More importantly, Pyppeteer can be configured to run on a specific version of Chromium, which doesn’t auto-update. That solves our problem with the constantly changing Chrome browser. In fact, with Pyppeteer, there is no middleman — no chromedriver.exe that could update to an incompatible version. I’ve seen chromedriver.exe updates cause widespread crashes for thousands of users online. Pyppeteer avoids this problem because it communicates directly with Chromium. This results in more predictable behavior and removes the need for containerization.

    Based on your experience, which tool would you say is better?

    Pyppeteer is supposedly less resource intensive...but in our experience it has far more CPU usage than Selenium. Selenium has unpredictable performance week to week based on chromdriver updates.

    Continue reading...

Compartilhe esta Página