Event Handler Execution Logs
Every event handler execution - whether it succeeds, fails, or times out - is recorded in the activity logs. This gives you full visibility into what your automation is doing.
Accessing Logs
- Navigate to Apps → ScriptForge → Activity Log
- Filter by Feature: Event Handlers to see only event handler logs
- Click any entry to see full details
Log Entry Contents
Each log entry includes:
| Field | Description |
|---|---|
| Event Handler Name | Which event handler fired |
| Event | The event that triggered it (e.g., avi:jira:created:issue) |
| Timestamp | When execution started |
| Duration | Execution time in milliseconds |
| Status | Success, Error, or Timeout |
| Console Output | All console.log, console.warn, console.error statements |
| Return Value | The value returned by the script (if any) |
| Error Details | Error message and stack trace (if execution failed) |
| Context | Issue key, project, user who triggered the event |
Filtering and Searching
- By status: Show only errors to identify problems
- By event handler: Show executions for a specific event handler
- By date: Narrow to a time window
- By text: Search within output or error messages
Troubleshooting with Logs
Script Not Firing
If an event handler isn't executing:
- Check the logs - if there is no entry at all, the condition may be failing
- Verify the event handler is enabled
- Confirm the event type matches what's happening
- Check the project filter - it might be scoped to a different project
Script Failing
If the log shows "Error":
- Read the error message and stack trace
- Common issues: calling methods on
undefined(event data shape may differ from expected), timeout for large JQL queries, permissions errors when usingrunAs: 'user'
Script Running But No Effect
If the log shows "Success" but nothing happened:
- Check the console output - did your conditions inside the script evaluate as expected?
- Add
console.logstatements to trace the execution path - Verify the Canarys HAPI calls are
awaited - forgettingawaiton async operations means they may not complete before the script ends
Loop Detection Logs
If ScriptForge detects a potential infinite loop (an event handler triggering events that trigger the same event handler), the log entry shows a loop detection warning and the execution is halted. Review the chain of events to break the cycle - typically by adding a condition that prevents re-triggering.