Closed Bug 1105567 Opened 5 years ago Closed 5 years ago
Selecting the recently-taken image in the Camera app (taken before formatting storage space) after formatting storage space crashes the Camera app
46 bytes, text/x-github-pull-request
|Details | Review|
45 bytes, text/plain
6.60 MB, video/mp4
Steps: 01 - Open the Settings app. 02 - Ensure that pictures are saved to the internal storage space (which is currently empty, as an example). 03 - Go to the Camera app and take a picture. Ensure that it appears in the lower left corner as a recently-taken picture. 04 - Go back to the Settings app and format the internal storage space. 05 - Navigate back to the Camera app, via long-pressing the home button. 06 - Tap on the recently-taken picture. 07 - The Camera app quits. (presumably crashes?) The Camera app should not quit/crash. It should no longer show the recently-taken picture instead. Video coming up. Setting needinfo? from Mike and David, our Camera app module owners on how to best move this forward. === $ ./check_versions.py Serial: e444da58 (State: device) Build ID 20141126040207 Gaia Revision 41b7be7c67167f367c3c4982ff08651d55455373 Gaia Date 2014-11-26 08:23:31 Gecko Revision https://hg.mozilla.org/mozilla-central/rev/7bcc6573d204 Gecko Version 36.0a1 Device Name flame Firmware(Release) 4.4.2 Firmware(Incremental) eng.cltbld.20141126.072757 Firmware Date Wed Nov 26 07:28:11 EST 2014 Bootloader L1TC00011880
dhylands, is there an event the Camera app can/should listen for to know the memory card has been nuked?
Flags: needinfo?(mhabicher) → needinfo?(dhylands)
formatting the sdcard will essentially do an unmount/format/re-mount Which is more or less the same thing as "sharing with the PC", have the PC remove all of the files, and remount. Formatting is just one way of removing all of the files. My understanding was that the media db would do an incremental scan if the media goes an available->sharing->available cycle, and only does a full scan if the media goes tthrough a available->unavailable->available cycle. Removing an sdcard and formatting an sdcard should both go through the available->unavailable->available cycle.
Wilson, based on comment 2, I think this is something the app can manage.
Flags: needinfo?(mhabicher) → needinfo?(wilsonpage)
dhylands: Where should I be listening for these events?
Flags: needinfo?(wilsonpage) → needinfo?(dhylands)
(In reply to Wilson Page [:wilsonpage] from comment #4) > dhylands: Where should I be listening for these events? Basically, you register with device storage using addEventListener like this: https://github.com/mozilla-b2g/gaia/blob/master/shared/js/mediadb.js#L700 Whether it makes sense to register directly with device storage or add something to the mediadb code may depend on the app in question.
Setting needinfo? in case this fell off the radar, thanks.
Flags: needinfo?(dflanagan) → needinfo?(wilsonpage)
I don't have time this week to look into this I'm afraid. Flagging dmarcos and justindarc to see if they have free cycles.
Blocking Reason: Camera app crashes/quits in a common scenario. Justin, please take a look at this. Thanks Hema
blocking-b2g: --- → 2.2+
Target Milestone: --- → 2.2 S7 (6mar)
Attachment #8568037 - Flags: review?(dmarcos)
Comment on attachment 8568037 [details] [review] [gaia] justindarc:bug1105567 > mozilla-b2g:v2.2 It looks good. We need a unit test for that new method.
Attachment #8568037 - Flags: review?(dmarcos) → review+
Comment on attachment 8576848 [details] [review] [gaia] justindarc:bug1105567 > mozilla-b2g:master Diego: I've corrected the branch for this patch and added a test for the new method as you requested.
Attachment #8576848 - Flags: review?(dmarcos)
Attachment #8576848 - Flags: review?(dmarcos) → review+
Pull request has landed in master: https://github.com/mozilla-b2g/gaia/commit/10dcd335d588997fc12845e9197de89228664f95
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Please request Gaia v2.2 on this when you get a chance.
Comment on attachment 8576848 [details] [review] [gaia] justindarc:bug1105567 > mozilla-b2g:master [Approval Request Comment] [Bug caused by] (feature/regressing bug #): N/A [User impact] if declined: User can format their media storage, return to Camera and crash the app. [Testing completed]: Added unit tests, performed manual testing. [Risk to taking this patch] (and alternatives if risky): Low/None [String changes made]: None
Attachment #8576848 - Flags: approval-gaia-v2.2?(bbajaj)
Attachment #8576848 - Flags: approval-gaia-v2.2?(bbajaj) → approval-gaia-v2.2+
This issue has been verified fixed on Flame 3.0. Following STR, at step 6 the preview picture is no longer present that could result to this crash. If I was already viewing the picture in Preview, it would take me back to Camera viewfinder without issue. Device: Flame 3.0 Master (full flash 319MB mem) BuildID: 20150317073344 Gaia: 738987bd80b0ddb4ccf853855388c2627e19dcc1 Gecko: 008b3f65a7e0 Gonk: b83fc73de7b64594cd74b33e498bf08332b5d87b Version: 39.0a1 (3.0 Master) Firmware Version: v18D-1 User Agent: Mozilla/5.0 (Mobile; rv:39.0) Gecko/39.0 Firefox/39.0 Leaving verifyme keyword for 2.2 verification.
QA Whiteboard: [QAnalyst-Triage+]
This bug has been successfully verified on latest Flame v2.2. See attachment: verified_v2.2.mp4 Reproduce rate: 0/5 STR: 1.Ensure that pictures are saved to the internal storage. 2.Open Camera app and take a picture. 3.Go to the Settings and format the internal storage. 4.Long press the Home button and tap on Camera app. **No recently-taken picture icon and Camera app will not quit. Flame 2.2 (Pass): Build ID 20150322002503 Gaia Revision 44c62060581fde8de1e12e94cf55e9673b401a47 Gaia Date 2015-03-20 19:05:17 Gecko Revision https://hg.mozilla.org/releases/mozilla-b2g37_v2_2/rev/e6140a32902a Gecko Version 37.0 Device Name flame Firmware(Release) 4.4.2 Firmware(Incremental) eng.cltbld.20150322.043216 Firmware Date Sun Mar 22 04:32:27 EDT 2015 Bootloader L1TC000118D0
QA Whiteboard: [QAnalyst-Triage+] → [QAnalyst-Triage+][MGSEI-Triage+]
You need to log in before you can comment on or make changes to this bug.