shellCheckOutput doesn't handle return value of None when calling self.shell

RESOLVED FIXED

Status

Testing
Mozbase
RESOLVED FIXED
5 years ago
3 years ago

People

(Reporter: jgriffin, Assigned: ahal)

Tracking

Trunk
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

5 years ago
See http://mxr.mozilla.org/mozilla-central/source/testing/mozbase/mozdevice/mozdevice/devicemanager.py#64.

The DMError expects that retval will be an integer, but sometimes it can be None:

http://mxr.mozilla.org/mozilla-central/source/testing/mozbase/mozdevice/mozdevice/devicemanagerADB.py#153

This got triggered on a TBPL Marionette run:

https://tbpl.mozilla.org/php/getParsedLog.php?id=17034784&tree=Firefox#error0

Updated

5 years ago
Blocks: 809437

Updated

5 years ago
Blocks: 812149
(Assignee)

Updated

5 years ago
Assignee: nobody → ahalberstadt
Status: NEW → ASSIGNED
(Assignee)

Comment 1

5 years ago
So the fact that we are returning None here: http://mxr.mozilla.org/mozilla-central/source/testing/mozbase/mozdevice/mozdevice/devicemanagerADB.py#153 means that either:

1) There is no return code in the process output
2) There are things being appended after the return code
3) The return code is being corrupted

In all three cases there is something that went wrong. In the best case we need a more robust way of parsing out the return code. In the worst case this is a side effect of a deeper issue in adb or related to how we call adb.
(Assignee)

Comment 2

5 years ago
Created attachment 683263 [details] [diff] [review]
Patch 1.0 - Fix

I filed bug 813266 to look into why we are hitting that codepath in the first place.

For this bug a quick fix to prevent errors being hidden in the future should be good enough.
Attachment #683263 - Flags: review?(jgriffin)
(Reporter)

Updated

5 years ago
Attachment #683263 - Flags: review?(jgriffin) → review+
(Assignee)

Comment 3

5 years ago
https://github.com/mozilla/mozbase/commit/32538b55548e59b19f045c6df1601942819c46dc

This is minor/rare enough that I won't bother cherry picking into m-c.
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
I got a similar error like this, while running a gaia-ui-test and trying to repeat it 50 times. I filed bug 1099985 for it.
You need to log in before you can comment on or make changes to this bug.