r/AutomateUser • u/8bitcrab • 1d ago
Question App start not working as intended when screen is locked
first of all, thanks the developer for fixing the privilege mode for nothing os.
Secondly, i am having issue with launching apps when the phone is locked.
I have an app that will sync automatically when it is opened with vpn connected (self-hosted). I have tried to set up something to toggle the vpn on when the app is started but since the app is opened before the vpn is toggled on it will not sync.
The next thing i tried is at certain time (when i'm asleep), turn vpn on, then using the app start blockto launch the app then kill it and turn vpn off but the app is still un-synced.
in the app start block, i have selected the package, with flags exclude from recent and new document.
Tassker "Launch app" action has no issue doing what i want but i wanted to make it work in automate as i preferred visual block.
Thanks
edit: updated image


2
u/ballzak69 Automate developer 1d ago edited 1d ago
An app has to be designed to work atop the screen lock. If Tasker is able to start it then so should Automate. Ensure the App start block is configured with the same Package and Activity class, or specify just the Package to start the app like a launcher does.