CLI Usage
Overview
WebRunner can be executed directly from the command line using the je_web_runner module.
Commands
Execute a single JSON action file:
python -m je_web_runner -e actions.json
python -m je_web_runner --execute_file actions.json
Execute all JSON files in a directory:
python -m je_web_runner -d ./actions/
python -m je_web_runner --execute_dir ./actions/
Execute a JSON action string directly:
python -m je_web_runner --execute_str '[["WR_get_webdriver_manager", {"webdriver_name": "chrome"}], ["WR_quit"]]'
Command Reference
Flag |
Short |
Description |
|---|---|---|
|
|
Execute a single JSON action file |
|
|
Execute all JSON files in a directory |
|
Execute a JSON action string directly |
JSON File Format
The JSON file should contain an array of action lists:
[
["WR_get_webdriver_manager", {"webdriver_name": "chrome"}],
["WR_to_url", {"url": "https://example.com"}],
["WR_quit"]
]
Note
On Windows, the --execute_str option may require double JSON parsing
due to shell escaping. WebRunner handles this automatically.
Error Handling
If no arguments are provided, WebRunner raises a WebRunnerExecuteException.
All errors are printed to stderr and the process exits with code 1.