Closed Bug 1160194 Opened 9 years ago Closed 9 years ago

Time set unnecessarily in install_app

Categories

(Release Engineering :: Applications: MozharnessCore, defect)

defect
Not set
normal

Tracking

(firefox40 fixed)

RESOLVED FIXED
Tracking Status
firefox40 --- fixed

People

(Reporter: gbrown, Assigned: gbrown)

References

Details

Attachments

(1 file)

ADBDeviceHandler's install_app() calls set_device_time(). I don't think time-setting is needed, and it seems to be implicated in bug 1051908.

On the Android emulators, time is synced with the host, so the install_app time set does nothing:

13:07:20     INFO - Getting output from command: ['/builds/slave/test/build/android-sdk18/platform-tools/adb', '-s', 'emulator-5554', 'shell', 'date']
13:07:20     INFO - Copy/paste: /builds/slave/test/build/android-sdk18/platform-tools/adb -s emulator-5554 shell date
13:07:20     INFO - Reading from file tmpfile_stdout
13:07:20     INFO - Output received:
13:07:20     INFO -  Tue Apr 28 13:07:20 PDT 2015
13:07:20     INFO - Tue Apr 28 13:07:20 PDT 2015
13:07:20     INFO - Running command: ['/builds/slave/test/build/android-sdk18/platform-tools/adb', '-s', 'emulator-5554', 'shell', 'date', '-s', '20150428.130720']
13:07:20     INFO - Copy/paste: /builds/slave/test/build/android-sdk18/platform-tools/adb -s emulator-5554 shell date -s 20150428.130720
13:07:20     INFO -  Tue Apr 28 13:07:20 PDT 2015
13:07:20     INFO - Return code: 0
13:07:20     INFO - Getting output from command: ['/builds/slave/test/build/android-sdk18/platform-tools/adb', '-s', 'emulator-5554', 'shell', 'date']
13:07:20     INFO - Copy/paste: /builds/slave/test/build/android-sdk18/platform-tools/adb -s emulator-5554 shell date
13:07:21     INFO - Reading from file tmpfile_stdout
13:07:21     INFO - Output received:
13:07:21     INFO -  Tue Apr 28 13:07:20 PDT 2015
13:07:21     INFO - Tue Apr 28 13:07:20 PDT 2015


Time setting is needed on pandas, but those jobs use a different mechanism.
This removes the call to set the time on the device; it is never needed on the emulators, and seems to hang intermittently.

I thought the comments here had outlived their usefulness, and some obviously pertain to Tegras, so removed them.

I also noticed we check for prior application installation (ls /data/data/<package>), but that is always negative in CI, since the emulators start with a fresh image. I removed this check also, simply to remove another possible adb hang.
Attachment #8600396 - Flags: review?(kmoir)
https://treeherder.mozilla.org/#/jobs?repo=try&revision=6c531f21679e

15:30:23     INFO - Getting output from command: ['/builds/slave/test/build/android-sdk18/platform-tools/adb', '-s', 'emulator-5554', 'shell', 'getprop', 'sys.boot_completed']
15:30:23     INFO - Copy/paste: /builds/slave/test/build/android-sdk18/platform-tools/adb -s emulator-5554 shell getprop sys.boot_completed
15:30:24     INFO - Reading from file tmpfile_stdout
15:30:24     INFO - Output received:
15:30:24     INFO -  1
15:30:24     INFO - Installing Fennec for test-1
15:30:24     INFO - Getting output from command: ['/builds/slave/test/build/android-sdk18/platform-tools/adb', '-s', 'emulator-5554', 'install', '-r', '/builds/slave/test/build/fennec-40.0a1.en-US.android-arm.apk']
15:30:24     INFO - Copy/paste: /builds/slave/test/build/android-sdk18/platform-tools/adb -s emulator-5554 install -r /builds/slave/test/build/fennec-40.0a1.en-US.android-arm.apk
15:32:09     INFO - Reading from file tmpfile_stdout
15:32:09     INFO - Output received:
15:32:09     INFO -  	pkg: /data/local/tmp/fennec-40.0a1.en-US.android-arm.apk
15:32:09     INFO -  Success
15:32:09     INFO - Reading from file tmpfile_stderr
15:32:09     INFO - Finished installing apps for test-1
Comment on attachment 8600396 [details] [diff] [review]
simplify adb install_app

Yay for removing spurious code!
Attachment #8600396 - Flags: review?(kmoir) → review+
https://hg.mozilla.org/mozilla-central/rev/f8235c9b93e8
Status: NEW → RESOLVED
Closed: 9 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: