android - Scheduling jobScheduler jobs via adb in rooted device -


i'm using jobscheduler api scheduling repeated job. testing, while running command adb shell cmd jobscheduler run -f com.foo.bar.application 1. working fine in non rooted device when execute in rooted device, i'm getting following exception--

java.lang.securityexception: uid 0 not permitted force scheduled jobs 

the run-as reports it's not debuggable app.

how test on rooted device?

you can try unroot adb shell.

the normal uid 2000

uid=2000(shell) gid=2000(shell) 

you can switch adb non rooted mode with

adb unroot 

then try run command


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -