Application Launched Trigger only gets invoked on first launch of MacroDroid, not on consecutive launches.

Nyx

New member
I use MacroDroid to lock me out of certain apps if I spend too much time on them. For that I have created a macro that triggers every time an application is launched, starts a timer if it is one of the limited apps, and closes the app if the timer is above my set limit. It also closes MacroDroid if I open it during a set timeframe after the time limit was reached, so I can't simply reset the timer. This has worked great in the past.

For a while now, MacroDroid has closed as it should when launching it for the first time, but stayed open when trying to launch it again. I looked at the log and noticed that the macro does not get invoked on the second launch and after.
This does not happen with the other specified apps, only with MacroDroid, so it's probably not a phone settings or battery saver issue (MacroDroid is also exempt from battery saver and has admin access to my phone - Pixel 6a with CalyxOS). The macro has worked in the past and I haven't changed it since then. Since the macro gets invoked on some launches on MacroDroid it is theoretically functional.
I have the MacroDroid Helper app installed with admin access as well.

I am genuinely confused as to why this is happening and how I can resolve this. Any help would be apprechiated.
 

MacroDroidDev

Administrator
Staff member
MacroDroid does have a different mechanism for detecting if it's in the foreground or not so it makes sense that this can break when the app launch trigger for other apps does not. I've had a quick play around and I wasn't able to recreate the problem you are seeing and the trigger seems to fire every time I launch MacroDroid for me. It's possible the issue is related to the macro you are using so it would be good if you could use the report a bug option in the troubleshooting section of your app and include the relevant macro(s) so I can try and recreate with exactly what you are using.
 
Top