Preventing Infinite Loop in MS Power Automate (MS Flow)
When a MS Flow is setup with the trigger "When item is created or modified" and the flow updates an item on the same list, an infinite trigger may occur.
Power automate will warn us with "Actions in this flow may result in an infinite trigger loop. Please ensure you add appropriate conditional checks to prevent this flow from triggering itself".
To prevent an infinite loop, create a dedicated MS flow user, and then update the connections so that this user updates the list item. Then setup a trigger condition with the following line (updating the {user email}):
@not(equals(triggerOutputs()?['body/Editor/Email'],'{user email}'))
This will prevent the trigger being called if updated by the flow itself.
https://www.sharepointpro.com.au