New issue
Advanced search Search tips

Issue 651852 link

Starred by 1 user

Issue metadata

Status: Assigned
Owner:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 3
Type: Bug



Sign in to add a comment

VideoRecorder fails to start recording in some devices

Project Member Reported by prabhur@chromium.org, Sep 30 2016

Issue description

File: third_party/catapult/devil/devil/android/tools/video_recorder.py

Videorecorder records video to a device file which is located at:
'/sdcard/screen-recording.mp4'.

In some devices for example, "cherry Mobile - Spice Mi-498" Android One 6.0.1 which is a svelte configured device /sdcard is a symbolic link
pointing to /storage/self/primary. Recording to this location fails with "path not found" error.

There are two issues here:
1) The start recording code assumes every device has an external storage.

One way to fix this is to take _device_file as a parameter so the caller can save to whatever location is valid for the device.

2) VideoRecorder._Record relies on specific output from screenrecord to return. 
if line.startswith('Content area is '):
        self._started.set()

So when screenrecord fails to start (due to whatever reason), the  
self._started.wait(timeout) call just blocks indefinitely (when timeout == None). 
Essentially when screenrecord fails to start, VideoRecorder blocks forever. It should return back to the caller with an error.
The fix would be set timeout to a default value other than None.


 
Components: -Infra>Client>Android
Status: Assigned (was: Untriaged)

Sign in to add a comment