Tag Change Event Script Stops Executing (Ignition 8.3.6)

I’m running Ignition 8.3.6 and have a Gateway Tag Change Event script that performs some data transformation and then inserts the results into MongoDB.

The event is configured with a wildcard tag path, for example:

Code

[default]ABC/default/*/*/*/Time

The issue I’m seeing is that sometimes, probably after a Gateway restart (not sure), the Tag Change Event simply stops executing. The script doesn’t run at all until I make a change to it (for example, adding a logger statement or editing the script in any way). Once I do that, it starts working again as expected.

Has anyone else run into this behavior? Is this a known bug with Tag Change Event scripts, or is there a recommended workaround to ensure the scripts will run reliably?

Are you sure your code isn't stalling? Tag Change Events are assigned a single thread to process events (in order), and if the code blocks for any reason, no more events are processed. You should look at a thread dump the next time it gets stuck. (Or open a support ticket to help with this analysis.)