Building & Deploying RPA Solutions — Python vs Robot Framework

Building and deploying RPA solutions does not have to burn a hole in your pocket.

Morgan Young
4 min readNov 11, 2022

I’ve been into RPA for a while. In 2019 I started working for a couple of years as a Business Analyst in the RPA team at the University of Cambridge, taking really long and often terribly designed processes and trying to automate them.

As most large organisations do, they bought an extremely expensive contract with a gen-1 RPA provider (UiPath) and a management consultancy to then tell them how to use the RPA software…

That was my first introduction. The gen-1 tools are very low-code, drag and drop type systems which for me isn’t great because it’s unfamiliar and locks you into a flat out exploitative pricing model. I wouldn’t recommend them to anyone.

Python friendly tools have helped.

A while after those big tools hit the scene, people realised what an exploitative piece of marketing/tech/platform lock in that RPA is, especially with the gen-1 providers, and companies such as Robocorp started popping up allowing you to use primarily Robot Framework (which is open source) to automate processes and then use their Robocorp Cloud platform to deploy and run these automations.

It’s good (and their team are exceptional) but it will still cost you $49pm. If you just want to run a web automation that clicks on a few buttons and downloads some files, then that is crazy money. Also, I’m not a huge fan of Robot Framework. Once you start getting slightly complex with the logic, it gets a bit… messy.

This is an example of logging into a website in Robot Framework & Selenium

So, I started to experiment with other ways of building and deploying automations. I had used a lot of Lambdas with python on AWS and the Serverless Framework previously and, seeing how low cost it was, I really wanted to see if I could get something running on there. After a lot of trial and error, I cracked it.

This python code does a similar task to the Robot Framework code above

Some problems I faced trying to run the most common automation libraries (like Selenium) on Lambdas:

  1. Selenium requires compability between the Selenium version and it’s associated Webdriver package (Chromedriver, Geckodriver etc.) AND compatability between the Webdriver and the version of the browser itself (like Chromium). This is handled for you in Robot Framework/Robocorp Cloud.
  2. When you set up Lambda as an HTTP or Flask REST API it has a max execution time of 30s, which isn’t long enough for a lot of web based automation.
  3. It can involve other AWS services to trigger/run that Robocorp handle out of the box, such as SQS or API Gateway.

And how I eventually solved these:

  1. Use this awesome docker-selenium-lambda setup. It automatically sorts out compatibility between different versions of the various parts as well as packages it all up ready to go for use on Lambda.
  2. Set up another service, like a CRON job, or API Gateway and SQS to queue up the API requests and then let your Lambda loose on them. No 30s timeout there!
  3. Use Serverless Framework and/or Terraform to script the deployment of these other resources really easily.
Decision time

So, using Robot Framework and deploying on Robocorp or using Python and deploying on AWS using a Lambda function?

Robot Framework & Robocorp:
1. $49/m minimum.
2. Code gets messier when you include complex business logic.
3. $0.10 per extra run minute
4. You can run desktop automations orchestrated remotely, which you can’t in Lambda.

Python & AWS Lambda:
1. Will probably cost you $0.01/m
2. It’s the code you’re used to and you have access to every single python package, just the same as Robot Framework.
3. No run limits.
4. Web only, you can’t run pointy clicky desktop automations on Lambda.

For me, I spend time mainly in the web automation space, so the Python & AWS Lambda combo wins out. Also, it is immensely cheaper to run.

Either way, you’re still winning vs using a gen-1 provider like UiPath!

— — — — — — — — — — — — — — — — — — — — — — — — — — — —

I’m a Product Manager in the UK who talks about trying to build things that people love to use 🚀. I currently look after a mobile application with over 80k users and write about product management and agile stuff 🔥.

You can find more of my writing here.

--

--

Morgan Young

Product Manager. I talk about trying to build stuff that people love to use 🔥