Closed Bug 915061 Opened 12 years ago Closed 12 years ago

Add gaia build flag to keep remote debugging turned on

Categories

(Firefox OS Graveyard :: Gaia, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: benfrancis, Assigned: ochameau)

Details

Attachments

(2 files)

Since bug 810092 and bug 874484 landed remote debugging now gets turned off: * During make reset-gaia (was already the case) * When the screen locks itself * After 12 hours of being set This is very frustrating when working on Gaia on a device. I propose adding a build flag to make reset-gaia (either opt-in or opt-out) which keeps remote debugging alive by: * Turning the remote debugging setting on * Setting the 12 hour timeout to zero (see Dave's script) * Turning off the lock screen? The alternative is that all Gaia developers create a custom build with these things hard coded (as some people do now). This probably doesn't help third party app developers but if they turn off the lock screen they will only be irritated once every twelve hours...
This is the script: https://gist.github.com/dhylands/6253999 which turns off the 12-hour timer (which is controlled via a pref)
If looks like the setting default for the remote debugger is devtools.debugger.remote-enabled found in profile/defaults/settings.json So I think if you pulled, edited, and pushed that file after resetting gaia and before starting b2g, then it would leave the debugger on.
No need to add a new flag, we should tweak prefs and settings with the existing gaia build flag DEVICE_DEBUG, that already automatically enable remote debugging: https://github.com/mozilla-b2g/gaia/blob/master/build/preferences.js#L155-L160
(In reply to Ben Francis [:benfrancis] from comment #0) > I propose adding a build flag to make reset-gaia (either opt-in or opt-out) > which keeps remote debugging alive by: FWIW, I'd vote for opt-in: The line between resetting gaia and using a phone for dev-only purposes (i.e. being willing to reduce the security) is blurry, but I there's no way to find out if a given reset was a one-time thing or not. Could we trigger this opt-in via commonly used workflows for developers? Something like the DEBUG=1 option comes into mind...
Uhm...what Alexandre said :O
Attached patch force-adb.patchSplinter Review
FTR this is the patch I use on my Gecko builds. Ideally, I'd like the same behaviour than my patch controlled by a pref that I'd set in build/custom-prefs.js.
Attached file pull request 12301
Assignee: nobody → poirot.alex
Attachment #806727 - Flags: review?(yurenju.mozilla)
I also added other prefs/settings to ease working with a device and allowed debugging certified apps (it has been recently restricted for production device)
Comment on attachment 806727 [details] pull request 12301 looks good and verified on unagi, r=yurenju
Attachment #806727 - Flags: review?(yurenju.mozilla) → review+
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: