DEV Community

Mehedi Hassan Shifat
Mehedi Hassan Shifat

Posted on AI-assisted

Can your Odoo automations trigger each other forever?

With enough automated actions, one of them will eventually write a field that another one watches. Odoo's automation module defines exactly when that happens: create triggers, write triggers, and special triggers (stage, state, priority, user, tags, archive) that watch a specific field.

Disclosure: I make a paid Odoo module that draws this map (link at the bottom).

That means the chain is computable. For each automation, look at what its actions write (object-write actions give a field path, Python actions can be read for write({...}), record.field = ... and env[...].create), and link it to every active automation that listens to that model and field. Strongly connected groups are loops, and two automations writing the same field on the same event is a conflict.

I built a module that draws that map, grouped by model, and flags loops, conflicts, rules with no action, code that no longer compiles, and schedules that keep failing. It's called Automation Map, 39 EUR on the Apps Store: https://apps.odoo.com/apps/modules/19.0/automation_map/

It reads Python statically, so code that builds model or field names dynamically can't be followed.

Top comments (0)