Why "Aw, snap!" or memory error appear when running automations in Chrome browser?
Issue:
When the bots are executing long running processes and huge number of transactions at some point the job fails with either memory error or "Aw, snap!" browser error.
Resolution:
When getting the "Aw, Snap" error or another error code instead of a webpage, Chrome is having problems loading. Sometimes the page loads slowly or does not open at all.
This issue occurs when the process runs for a long time and the browser cache increases and crashes.
A couple of troubleshooting steps that could help in this scenario are:
- Reload the page.
- Wait for the issue to occur, handle the exception, close the browser, and open the browser. Ensure the status of the failed transaction is retried.
- After every few hundred or thousand records are processed, close and open the browser.
- Build a script that deletes cache and cookies for All time when the error occurs; execute the script.
- After executing it, the browser needs to be restarted.