New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rewrite snippet management to account for new launch protocol. #216
Conversation
* Snippet will now try and detect v1 protocol and fall back to v0 if that fails. * Make snippet_client and sl4a_client responsible for bringup and teardown of their apks, instead of sprinkling the logic for this between jsonrpc_client_base, snippet_client, sl4a_client and android_device. This is needed because the retry structure is now different for v1 snippets. * Change how device port is handled. Device port comes from device side in v1 snippets. * Speed up snippet startup by avoiding extra stop before starting a snippet.
Review status: 0 of 10 files reviewed at latest revision, 6 unresolved discussions. mobly/utils.py, line 191 at r1 (raw file):
Simply use mobly/utils.py, line 429 at r1 (raw file):
If this is specific to mobly/controllers/android_device_lib/jsonrpc_client_base.py, line 124 at r1 (raw file):
Should this method's name be changed to something like mobly/controllers/android_device_lib/snippet_client.py, line 35 at r1 (raw file):
Could we keep this in base class and assign mobly/controllers/android_device_lib/snippet_client.py, line 50 at r1 (raw file):
Can we add some context on the v0 and v1 changes in the docstring here? tools/sl4a_shell.py, line 67 at r1 (raw file):
why this change? Comments from Reviewable |
Review status: 0 of 10 files reviewed at latest revision, 6 unresolved discussions. mobly/utils.py, line 191 at r1 (raw file): Previously, xpconanfan (Ang Li) wrote…
Done. mobly/utils.py, line 429 at r1 (raw file): Previously, xpconanfan (Ang Li) wrote…
Changed this text; it's not specific to AdbProxy. mobly/controllers/android_device_lib/jsonrpc_client_base.py, line 124 at r1 (raw file): Previously, xpconanfan (Ang Li) wrote…
Done. mobly/controllers/android_device_lib/snippet_client.py, line 35 at r1 (raw file): Previously, xpconanfan (Ang Li) wrote…
Actually it shouldn't be duped, because the start time of sl4a has nothing to do with the start time of snippet. I want to reduce the sl4a timeout again but I don't want to do that in this PR. The one in snippet will soon be deleted because v1 snippets don't have a timeout value like this. mobly/controllers/android_device_lib/snippet_client.py, line 50 at r1 (raw file): Previously, xpconanfan (Ang Li) wrote…
Done. tools/sl4a_shell.py, line 67 at r1 (raw file): Previously, xpconanfan (Ang Li) wrote…
The same line already exists in snippet_shell so this makes it consistent. It makes it easier to debug because you can just flip this value and rerun to get debug logs. (there's no file logging happening in the shells so there's no other way to view debug logs at the moment.) Comments from Reviewable |
Review status: 0 of 10 files reviewed at latest revision, 3 unresolved discussions. mobly/controllers/android_device_lib/snippet_client.py, line 35 at r1 (raw file): Previously, adorokhine (Alexander Dorokhine) wrote…
Should this comment mention the pending removal of this value? Comments from Reviewable |
Review status: 0 of 10 files reviewed at latest revision, 3 unresolved discussions. mobly/controllers/android_device_lib/snippet_client.py, line 35 at r1 (raw file): Previously, xpconanfan (Ang Li) wrote…
Done. Comments from Reviewable |
Review status: 0 of 10 files reviewed at latest revision, all discussions resolved. Comments from Reviewable |
fails.
of their apks, instead of sprinkling the logic for this between
jsonrpc_client_base, snippet_client, sl4a_client and android_device.
This is needed because the retry structure is now different for v1
snippets.
v1 snippets.
snippet.
Fixes #91
Fixes #215
This change is