Closed
Bug 987224
Opened 11 years ago
Closed 11 years ago
[B2G][Video]Unable to watch videos in video app after deleting two videos
Categories
(Firefox OS Graveyard :: Gaia::Video, defect)
Tracking
(blocking-b2g:1.4+, b2g-v1.4 fixed, b2g-v2.0 fixed)
People
(Reporter: rkuhlman, Assigned: rnicoletti)
References
Details
(Keywords: regression)
Attachments
(2 files)
If the user deletes two videos from the video app using the selection view, there is a chance that they will not be able to watch any videos until the app has been closed and restarted.
Repro Steps:
*prerequisite: have at least 3 videos stored on the sd card.
1) Updated Buri to BuildID: 20140324000202
2) Launch video app.
3) Enter selection view. (Tap the box outline in the lower right corner)
4) Select two videos and delete them by tapping the trashcan icon.
5) Press the 'X' in the upper left corner to exit selection view.
6) Tap on a video to watch it.
Actual:
The video flashes to indicate that it has been tapped, but otherwise nothing happens. The list of videos is still displayed and no videos can be launched.
Expected:
The video launches and plays and all expected UI is present. (play/pause, slider, etc)
Environmental Variables:
Device: Buri v1.4 Moz RIL
BuildID: 20140324000202
Gaia: 730670951e40b2317a167fcd07c398bb662d6e87
Gecko: a44f8b39c2c8
Version: 30.0a2
Firmware Version: v1.2-device.cfg
Notes:
Repro frequency: 40%
See attached: logcat
Reporter | ||
Updated•11 years ago
|
QA Contact: rkuhlman
Reporter | ||
Comment 2•11 years ago
|
||
Issue does not occur in v1.3
Environmental Variables:
Device: Buri v1.3 Moz RIL
BuildID: 20140324004001
Gaia: f7742fb4929cc57c9f72955ce5cebb8279745ac0
Gecko: e42b778a010f
Version: 28.0
Firmware Version: v1.2-device.cfg
Updated•11 years ago
|
blocking-b2g: --- → 1.4?
Keywords: regression,
regressionwindow-wanted
Comment 3•11 years ago
|
||
This issue started reproducing on the 12/13/14 1.4 build.
- Last Working -
Device: Buri Master v1.4 MOZ RIL
BuildID: 20131212040203
Gaia: 8952898bbc98dd31e25b647203791cf129867ff1
Gecko: 1ad9af3a2ab8
Version: 29.0a1
Firmware Version: V1.2-device.cfg
- First Broken -
Device: Buri Master 1.4 MOZ RIL
BuildID: 20131213040203
Gaia: 390b313a254a947d12e3cdbcde19d7d1619ff63c
Gecko: 8b5875dc7e31
Version: 29.0a1
Firmware Version: V1.2-device.cfg
**This looks to be a gaia issue**
last working gaia/first broken gecko = NO REPRO
Gaia: 8952898bbc98dd31e25b647203791cf129867ff1
Gecko: 8b5875dc7e31
first broken gaia/last working gecko = REPRO
Gaia: 390b313a254a947d12e3cdbcde19d7d1619ff63c
Gecko: 1ad9af3a2ab8
Push log: https://github.com/mozilla-b2g/gaia/compare/8952898bbc98dd31e25b647203791cf129867ff1...390b313a254a947d12e3cdbcde19d7d1619ff63c
Comment 5•11 years ago
|
||
If we can we should try to backout 903920 here to resolve this issue.
blocking-b2g: 1.4? → 1.4+
Comment 6•11 years ago
|
||
Johu,
Could you please do a quick investigation -- it looks like this is caused by the layout changes on video
Thanks
Hema
Flags: needinfo?(rnicoletti)
Flags: needinfo?(johu)
Comment 7•11 years ago
|
||
It is caused by bug 903920. I can provide a STR with 100% reproduce ratio:
Following rkuhlman's STR but only one step need to be changed:
1) Updated Buri to BuildID: 20140324000202
2) Launch video app.
3) Enter selection view. (Tap the box outline in the lower right corner)
4*) Select two *adjacent* videos from *bottom to top* and delete them by tapping the trashcan icon.
5) Press the 'X' in the upper left corner to exit selection view.
6) Tap on a video to watch it.
And in the console, you may find the following log:
[JavaScript Error: "TypeError: old is undefined" {file: "app://video.gaiamobile.org/gaia_build_defer_index.js" line: 595}]
For bug 903920 (tablet), we need to keep the currentVideo variable valid to have the focus when we delete the currentVideo. resetCurrentVideo handles such kind of case. It is called at the deleteFile[1]. But the removal of thumbnail from thumbnail list is async function call which is triggered by instead of the callback of mediadb[2].
The reason we need to select adjacent video from bottom to top is that: resetCurrentVideo find the next video file from UI to be the currentVideo. When we delete two videos at the same thing, the second deletion chooses the first deleted video as the currentVideo because the thumbnail isn't removed from thumbnail list.
That's the root cause. I think the patch may be simple like moving [1] to [3].
[1] https://github.com/mozilla-b2g/gaia/blob/624c781427ed48aec9907cffbc9158022bafb1b1/apps/video/js/video.js#L566-L571
[2] https://github.com/mozilla-b2g/gaia/blob/624c781427ed48aec9907cffbc9158022bafb1b1/apps/video/js/video.js#L576
[3] https://github.com/mozilla-b2g/gaia/blob/624c781427ed48aec9907cffbc9158022bafb1b1/apps/video/js/db.js#L130
Flags: needinfo?(johu)
Comment 8•11 years ago
|
||
Russ,
I don't have any capacity to take this one. Would you mind to take it? I think this is a easy bug. Please find more information at comment 7. If you need help, please need info me.
Assignee | ||
Comment 9•11 years ago
|
||
Thanks, John. I will take it.
Assignee: nobody → rnicoletti
Status: NEW → UNCONFIRMED
Ever confirmed: false
Flags: needinfo?(rnicoletti)
Assignee | ||
Updated•11 years ago
|
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Assignee | ||
Comment 10•11 years ago
|
||
John, I implemented your suggestion from comment #7. My testing of the patch confirmed it fixed the problem.
Attachment #8397248 -
Flags: review?(johu)
Comment 11•11 years ago
|
||
Comment on attachment 8397248 [details] [review]
Pull request: https://github.com/mozilla-b2g/gaia/pull/17664
Thanks Russ. It looks good. The travis is red. Please rebase your code and check if there is anything wrong in travis. Thanks.
Attachment #8397248 -
Flags: review?(johu) → review+
Assignee | ||
Comment 12•11 years ago
|
||
I created a new PR with rebased code (https://github.com/mozilla-b2g/gaia/pull/17721) and travis is green.
Merged into master:
https://github.com/mozilla-b2g/gaia/commit/8248f8da7a29757da9f7fd748a0d8d70f2bd4610
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Comment 13•11 years ago
|
||
status-b2g-v2.0:
--- → fixed
Target Milestone: --- → 1.4 S4 (28mar)
You need to log in
before you can comment on or make changes to this bug.
Description
•