Thanks for getting back to me, João (Big fan or your work).
I'm not sure which it is. Here's what I did yesterday to cause the problem.
1) I left home for the Doctor;s office.
Phone turns off WiFi, starts Bluetooth, turns on Mobile Data, sets screenlock to 15 minutes
2) I get about 10 blocks from home, remember I left my facemask at home, go back for it.
Phone turns on Wifi, turns off Bluetooth, turns off Mobile Data, sets screenlock to 72 hours
3) Pick up the mask and leave again
Phone turns off WiFi, starts Bluetooth, turns on Mobile Data, sets screenlock to 15 minutes
4) 50 miles later arrive at doctor's office
Phone turns on Wifi, turns off Bluetooth, but when it tries to turn off Mobile Data, I get an error message about missing permissions
.
.
.
6) Return home
Phone turns on Wifi, turns off Bluetooth, turns tries to turn off Mobile Data but I again get missing permissions message, tries to set screenlock to 72 hours but it still locks after 15 minutes.
7) Connect phone to PC (Windows 7) and enter the following commands.
adb devices
adb tcpip 5555
adb shell pm grant com.joaomgcd.autotools android.permission.WRITE_SECURE_SETTINGS
adb shell pm grant net.dinglisch.android.taskerm android.permission.WRITE_SECURE_SETTINGS
8) Things appear to go back to working, but several hours later I get a message asking to accept a RSA key. I check the "don't ask again" then the OK.
And it's back to normal.
Thanks.
tom