Day 4 - Testing, Debugging, and Logs

Learn how to validate, troubleshoot, and perfect your processes using Automize's built-in testing tools, debug mode, and logs.

Help CentreGetting Started

Day 4 - Testing, Debugging, and Logs

The goal is to learn how to validate, troubleshoot, and perfect your processes using Automize's built-in testing tools, debug mode, and logs.


1. Why Testing and Debugging Matter

Recording and editing are only half the job - testing is where automation becomes reliable.

Even a small change (like a window name or selector) can cause failures. Testing helps you:

  • Catch and fix issues early.

  • Ensure processes work consistently across runs.

  • Confirm logic, variables, and timing behave as expected.

  • Build confidence before moving to TEST or PRODUCTION environments.

Industry Insight:Top RPA teams spend as much time testing and debugging as they do recording and editing. A strong testing discipline prevents 90% of runtime issues.


2. Testing Modes in Automize

Automize provides multiple modes to execute and validate your processes safely.


Playback Mode

Runs the process in real time, just as it was recorded. Use this for end-to-end verification once editing is complete.

Key Uses:

  • Final validation before deployment.

  • Demonstrating the process to others.


Debug Mode

Executes the process step by step, pausing between activities. Use this to observe variable values, check selectors, and isolate problems.

Features:

  • Step-through execution.

  • Variable inspection panel.

  • Conditional pause and resume.

  • Ability to re-run specific sections.


Test Environment Settings

Each process can run in one of four environments:

  • DEV - for initial build and experimentation.

  • TEST - for validation by end users or QA.

  • STAGING - for final approval and integration testing.

  • PRODUCTION - for stable, client-facing automations.

Tip: Always test changes in DEV or TEST before switching to STAGING or PRODUCTION.


3. Hands-On Exercise: Testing Your Calculator Process

Objective: Debug and validate the calculator process you recorded earlier.


Steps

  1. Open your Calculator process in the Automize Web Portal.

  2. Set its environment to DEV.

  3. Open your Bot and on go to the play panel.

  4. Click the Debug option.

  5. Select the Calculator process and click Play.

  6. Observe the bot executing each step:

    • Watch each action highlight as it runs.

    • Press F7 to continue to the next activity.

  7. If a step fails (e.g., can't find Calculator), stop and review the parameters.

  8. Fix the issue, save, and re-run in debug mode.

  9. Once it runs cleanly, switch to Playback Mode for a full-speed test.

Success Criteria:The process completes without interruption, all variables hold the correct values, and the log shows "Success" for each activity.


4. Reading and Understanding Logs

Logs are your automation's "black box recorder." They capture everything Automize does - perfect for tracing what happened when something goes wrong. A typical extract from a log file looks as follow:

25-11-13 12:46:05 INFO  playbot.run_process - *********************************************
                                              ***** 2. OPEN HTTP://ABC.COM/LOGIN.ASPX *****
                                              *********************************************
                        action = browser_url, state size = 4, data = {'path': 'http://abc.com/Login.aspx', 'app': 'chrome', 'has_screenshot': False, 'button': 'left', 'coverPhoto': False, 'interval': 0.1, 'iterations': 1, 'position': 'absolute', 'window': None}
25-11-13 12:46:05 DEBUG playbot.initiate_app - title = chrome, extension = .aspx, application = chrome, hint = chrome
25-11-13 12:46:05 DEBUG browser.init - parameters = {'path': 'http://abc.com/Login.aspx', 'app': 'chrome', 'has_screenshot': False, 'button': 'left', 'coverPhoto': False, 'interval': 0.1, 'iterations': 1, 'position': 'absolute', 'window': None}
25-11-13 12:46:08 DEBUG browser.open_browser - browser = chrome, driver path = None, js path = C:\Users\user a\AppData\Local\Automize\Automize\Cache\inject.min.js
25-11-13 12:46:08 DEBUG browser.options - Options: ['allow-running-insecure-content', 'disable-dev-shm-usage', 'disable-extensions', 'disable-extensions-file-access-check', 'disable-extensions-http-throttling', 'disable-features=ChromeWhatsNewUI', 'disable-infobars', 'disable-notifications', 'disable-popup-blocking', 'enable-automation', 'ignore-certificate-errors', 'ignore-ssl-errors=yes', 'inprivate', 'lang=en-US', 'log-level=OFF', 'no-first-run', 'no-sandbox', 'no-service-autorun', 'password-store=basic', 'proxy-bypass-list=*', 'proxy-server=direct://', 'profile-directory=eb972ced-6b2a-4729-9406-d559cdc1f259', 'user-data-dir=C:\Users\user a\AppData\Local\Automize\Automize\eb972ced-6b2a-4729-9406-d559cdc1f259']

Log Components

SectionDescription
TimestampWhen each step ran.
LevelThe log level (debug, info, warning, error or critical).
Module and process nameFrom where the log was called.
MessageAdditional notes or system feedback.
VariablesKey variable values during execution.
Error DetailsFull traceback if something went wrong.

Accessing Logs

From the Bot: Open the Help menu item → Show log in Explorer / Finder → double click the file.


How to Use Logs Effectively

  • Review logs after every test run - even successful ones.

  • Look for unusually long step times or skipped activities.

  • Cross-check variable values against expected results.

  • Use timestamps to spot delays or misordered steps.

  • Copy log details when reporting issues to support or your team lead.


Common Log Scenarios

IssuePossible CauseFix
Selector not foundUI element changed or hiddenUpdate selector or add "Wait for Element"
Timeout exceededStep took longer than expectedIncrease wait or use dynamic delay
Variable undefinedVariable name mismatch or empty valueInitialise before use
Unexpected app windowPop-up or modal interferedAdd close or "If Exists" check

Log file security

Certain information should not be logged due to security and compliance requirements. Please review the Log File Security Guide to ensure your logging practices do not compromise your company’s policies or security controls.


5. Debugging Techniques

1. Isolate the Problem

  • Run only the failing section by temporarily disconnecting later connectors.

  • Check the activity just before the failure - often that's where the root cause lies.


2. Check Selectors

  • Use Preview Selector to confirm the element still exists.

  • Re-record the specific action if the UI has changed.


3. Adjust Waits and Delays

  • Use Wait for Element or Wait for Window instead of fixed delays.

  • Add conditional waits for dynamic elements.


4. Test Incrementally

Run your process in smaller parts:

  • Record → Test one section → Debug → Add next section.

  • This approach isolates issues early and avoids confusion.


5. Log Custom Messages

Use the Log Message activity to add helpful notes:

Log: "Starting calculation for user {UserName}"

This makes your logs easier to read later.


6. Use "Exception" Connectors

  • Connect the Exception path of critical steps to a "Handle Error" sub-process.

  • Add a log message or notification before stopping the process.


6. Hands-On Exercises

Exercise 1 - Controlled Error

  1. Copy your Calculator process.

  2. Change the write Calculator step to Write "Word".

  3. Run the process in Debug Mode.

  4. Observe the failure and open the log to locate the error.

  5. Fix the Wait for Window and re-run.

Goal: Identify and fix a deliberate failure through debugging.


Exercise 2 - Add Logging

  1. Add Process → Log activities at the start and end of your process.

  2. Example:

    Log: "Process started"

    Log: "Process completed successfully"

  3. Re-run and confirm both entries appear in the log.

Goal: Practice using logs for transparency and reporting.


Exercise 3 - Conditional Wait

  1. Insert a Wait for Window or Wait for Element before a key action.

  2. Set a timeout of 10 seconds.

  3. Add a log message if the wait fails.

  4. Test the process with and without the target window open.

Goal: Learn to handle timing issues dynamically.


7. Best Practices for Testing and Debugging

1. Test Early, Test Often

Run small sections frequently rather than the full process once. Catch small issues before they cascade.


2. Keep Logs Clean

Avoid unnecessary log spam - only log what's meaningful. But never skip logging errors, start times, or variable summaries.


3. Simulate Real Conditions

Use realistic data and system states during testing. Avoid perfect test scenarios that don't match production.


4. Read Logs Like a Story

Follow the flow line by line:

  • Start → Key variables → Success → Fail point → Recovery. This narrative approach helps you think like the bot.


5. Automate Error Handling

Add "Try / Catch"-style logic using Exception connectors or sub-processes. Don't let one minor failure stop the entire automation.


6. Industry Standards

These are standard across major RPA platforms:

  • Always test processes end-to-end before moving to production.

  • Maintain a test checklist for each environment.

  • Archive logs for auditing and compliance.

  • Use a standard naming format for test runs (e.g., Calc_Test_v1).


End of Day 4 Summary

By completing Day 4, you should now be able to:

✅ Run and validate automations in Playback and Debug modes
✅ Read, interpret, and act on logs
✅ Identify and fix selector, timing, and data issues
✅ Add meaningful logging to your processes
✅ Apply structured, professional debugging practices


Next Step - Day 5

Learn advanced RPA topics and optimisation, including error handling, performance tuning, and creating reliable production-ready processes.
Next

See it working on your own data

Everything documented here ships with the platform – try the document tools free, or go live in 7 days.