How to troubleshoot when email notification event is triggered by a scriptSummaryAn example here is an event "pa.job.dc.ended.with.warning" which is triggered by a script & sending emails with the subject line - [PA AppSec] Daily Data Collection completed with warningReleaseApplicable for all releases.InstructionsTo find which script in ServiceNow created the event pa.job.dc.ended.with.warning, you can follow these steps: 1. Search in System Logs Navigate to System Logs > Events in the ServiceNow application navigator.Filter the events by the name pa.job.dc.ended.with.warning.Check the "Created By" or "Source" fields for clues about what triggered the event. Sometimes, this can point directly to the script or scheduled job. 2. Search in Script Includes Use the global search bar or navigate to System Definition > Script Includes.Search for gs.eventQueue or gs.eventQueueScheduled along with the event name pa.job.dc.ended.with.warning.Review the results to identify the script include that created the event. 3. Check Business Rules Navigate to System Definition > Business Rules.Search for the event name pa.job.dc.ended.with.warning using the search bar.Review business rules for any gs.eventQueue or similar calls that reference this event. 4. Scheduled Jobs or Data Collection Jobs Since this event name references pa.job.dc (Performance Analytics job data collection), it might be related to a Performance Analytics data collection job.Navigate to Performance Analytics > Data Collector Jobs.Review the configurations of jobs that might end with warnings and check if any associated scripts or triggers generate this event.Look for [PA AppSec] Daily Data Collection 5. Scripts and Script Actions Navigate to System Policy > Events > Script Actions.Look for the event pa.job.dc.ended.with.warning in the list of script actions.Check if any script action is configured to trigger or process this event. 6. Debugging Tools Use the System Logs > Debug Logs feature to trace back the origin of the event.Enable debugging, then manually trigger the process you suspect might create the event.Look for gs.eventQueue or pa.job.dc.ended.with.warning in the logs. 7. Review Customizations If this event is custom, you may need to review the custom scripts, UI Actions, or Flow Designer actions in your instance for references to this event name. By systematically checking these areas, you should be able to trace the origin of the event pa.job.dc.ended.with.warning.