[Buri][BT]Can not open received file transfer from other MS/PC

RESOLVED FIXED

Status

Firefox OS
Gaia::Bluetooth
P1
normal
RESOLVED FIXED
5 years ago
4 years ago

People

(Reporter: sync-1, Assigned: iliu@mozilla.com, ianliu.moz@gmail.com)

Tracking

unspecified
ARM
Gonk (Firefox OS)
Dependency tree / graph
Bug Flags:
in-moztrap ?

Firefox Tracking Flags

(blocking-b2g:leo+, b2g18 fixed)

Details

(Whiteboard: [triaged][status: waiting on product input from sandip])

Attachments

(6 attachments)

(Reporter)

Description

5 years ago
+++ This bug was initially created as a clone of Bug #413307 +++
 
 Created an attachment (id=355527)
 picture
 
 DEFECT DESCRIPTION:
 Can not open received file transfer from other MS/PC
 
 REPRODUCING PROCEDURES:
 1.Use other MS/PC send picture/music/video(all media format) to Beetle lite FF
 2.After file transfer finished,try to open failed,pop up message"can not open received file---->KO
 
 EXPECTED BEHAVIOUR:
 For KO,should can open receive file tranfer from other MS/PC
 
 ASSOCIATE SPECIFICATION:
 
 TEST PLAN REFERENCE:
 
 TOOLS AND PLATFORMS USED:
 
 USER IMPACT:
 
 REPRODUCING RATE:
 
 For FT PR, Please list reference mobile's behavior:
 
 Firefox os  v1.0.1
 Mozilla build ID: 20130310070203.
 ++++++++++ end of initial bug #413307 description ++++++++++
 
 
 
 CONTACT INFO (Name,Phone number):
 
 DEFECT DESCRIPTION:
 
 REPRODUCING PROCEDURES:
 
 EXPECTED BEHAVIOUR:
 
 ASSOCIATE SPECIFICATION:
 
 TEST PLAN REFERENCE:
 
 TOOLS AND PLATFORMS USED:
 
 USER IMPACT:
 
 REPRODUCING RATE:
 
 For FT PR, Please list reference mobile's behavior:

Updated

5 years ago
blocking-b2g: --- → tef?
Can you please include here the file you are transferring as an attachment?
Flags: needinfo?(sync-1)

Comment 2

5 years ago
Created attachment 726360 [details]
picture file

such as this picture. it will not be opened after transferred, but later,if you go to gallery,you can see it.

Comment 3

5 years ago
in fact,I also tried two other pictures, non of them can be opened. but,seems mp3 file is ok,which can be played in music player when you click the notification.
Flags: needinfo?(sync-1)
I have successfully transferred the image through BT with the latest Gaia/Gecko. Any chance you can re-test with a newer one?

The tips I am using are:

Gecko: d8e8bee
Gaia: 633e14d

When clicking on the notification that tells me the download has been completed, the image is opened, clicking on the back button returns me to the gallery.
I also have successfully transferred the image through BT from my Mac with the build version 20130312230202.

Hi buri,
Does the issue only happen on MS/PC?

Updated

5 years ago
Priority: -- → P1
(Reporter)

Comment 6

5 years ago
On V1.0.1 is KO, Mozilla is modified for it(at master branch PR 838027). 
 Please merge to v1.0.1 branch.
bug 838027 is about Video transfer via Bluetooth, the attachment you are including is a picture. What is the real bug here?
Flags: needinfo?(sync-1)
triage: partner will retest on newer build. please renom if reproduced
blocking-b2g: tef? → ---

Updated

5 years ago
Whiteboard: [triaged]
(Reporter)

Comment 9

5 years ago
*.mp4, *.ogg, *.bmp open failed
Flags: needinfo?(sync-1)
(Reporter)

Comment 10

5 years ago
Created an attachment (id=373861)
 jpeg
 
 some file also can not open,such as jpeg,png,I have upload on attachmet
(Reporter)

Comment 11

5 years ago
Created attachment 729390 [details]
jpeg

Created an attachment (id=373861)
 jpeg
 
 some file also can not open,such as jpeg,png,I have upload on attachmet
(Reporter)

Comment 12

5 years ago
Created an attachment (id=373860)
 png
(Reporter)

Comment 13

5 years ago
Created attachment 729391 [details]
png

Created an attachment (id=373860)
 png
(Reporter)

Comment 14

5 years ago
some file also can not open,such as jpeg,png,I have upload on attachmet
 sometimes can open,sometimes can not open,if can not open,reset phone,then can open.
(Reporter)

Comment 15

5 years ago
can not open ogg file on version 120
(In reply to sync-1 from comment #14)
> some file also can not open,such as jpeg,png,I have upload on attachmet
>  sometimes can open,sometimes can not open,if can not open,reset phone,then
> can open.

For v1.0.1, Gallery app support to open these file type as following link.
https://github.com/mozilla-b2g/gaia/blob/v1.0.1/apps/gallery/manifest.webapp#L36
"type": ["image/jpeg", "image/png", "image/gif", "image/bmp"]
(In reply to sync-1 from comment #15)
> can not open ogg file on version 120

For v1.0.1, Music app support to open these file type as following link.
https://github.com/mozilla-b2g/gaia/blob/v1.0.1/apps/music/manifest.webapp#L20
"type": ["audio/mpeg", "audio/ogg", "audio/mp4"]
Hi sync-1,
Could you please help to check the file type before you open it via web-activity?
You may try to dump some log for the variable "fileType".
https://github.com/mozilla-b2g/gaia/blob/v1.0.1/apps/system/js/bluetooth_transfer.js#L462
(Reporter)

Comment 19

5 years ago
(In reply to comment #11)
 > Comment from Mozilla:Hi sync-1,
 > Could you please help to check the file type before you open it via
 > web-activity?
 > You may try to dump some log for the variable \"fileType\".
 > https://github.com/mozilla-b2g/gaia/blob/v1.0.1/apps/system/js/bluetooth_transfer.js#L462
 > 
 
 Hi:
   Sometimes It can open success,and the file type is right audio/ogg,but sometimes it open failed,and the file type is application/ogg ,and this dues to the transferInfos
(Assignee)

Updated

5 years ago
Assignee: nobody → iliu

Comment 20

5 years ago
(In reply to Ian Liu [:ianliu] from comment #18)
> Hi sync-1,
> Could you please help to check the file type before you open it via
> web-activity?
> You may try to dump some log for the variable "fileType".
> https://github.com/mozilla-b2g/gaia/blob/v1.0.1/apps/system/js/
> bluetooth_transfer.js#L462

Hi:
 Now the .ogg only be used for Ogg Vorbis audio files,may be we need to switch "application/ogg" to "audio/ogg" in gecko or change the logic in gaia.what do you think about this issue?

Comment 21

5 years ago
On our latest version,
AU_LINUX_GECKO_ICS_STRAWBERRY_V1.01.00.01.019.092
Firefox os  v1.0.1
Mozilla build ID:20130430070201

OGG File still has problem. 100% reproduable ,due to this reason ,I mark tef? again.
All other types are OK.

QA wanted
blocking-b2g: --- → tef?
Because of supported Bluetooth file transfer for Gallery/Music in v1.0.1. Bluetooth app is only considerate of image and audio filetype in the version. I would like to fix the issue in V1-train. Nominate leo+..
leo? as per comment 22
blocking-b2g: tef? → leo?
needinfo - product

See comment #9 -- do we need to extend the BT transfer to more gracefully handle these filetypes?
Flags: needinfo?(ffos-product)
For the issue, we could handle these filetype via MimeMapper.(https://github.com/mozilla-b2g/gaia/blob/master/shared/js/mime_mapper.js)
In general case, Bluetooth app could receive any kinds of filetype which is sent by other device. The scenario is much like opening the attached file in Email app.
blocking-b2g: leo? → tef?

Comment 26

5 years ago
Created attachment 746768 [details]
HCIDUMP

Hi:
  From the attached log, you can find the type is "application/ogg" during data link layer,maybe this is the point of this issue,I hope that the log can help you.

Comment 27

5 years ago
If we need to support *.ogg files with mimetype "video/ogg"("audio/ogg is already supported in music app"), we need bug 869859 fixed. Sounds like "application/ogg" should be also supported but that's not an often seen mimetype, it will be better to handle "application/ogg" with the logic of MimeMapper in shared/js.
Depends on: 869859
(In reply to qingluo.wang from comment #26)
> Created attachment 746768 [details]
> HCIDUMP
> 
> Hi:
>   From the attached log, you can find the type is "application/ogg" during
> data link layer,maybe this is the point of this issue,I hope that the log
> can help you.

It's really helpful. We cannot identify that the file is belong to audio or video via filetype "application/ogg". And we cannot really open the file by Music/Video app before choosing an app to open. In general case, Video app is able to handle both of them. I would like to add filetype "application/ogg" corresponding to video in MimeMapper utility.

Change the flag tef? remissly. Recovery it.
blocking-b2g: tef? → leo?
Sandip, this could use your input.
Flags: needinfo?(skamat)
Created attachment 747259 [details]
Pointer to Github pull request: https://github.com/mozilla-b2g/gaia/pull/9634

Pointer to Github pull-request
Comment on attachment 747259 [details]
Pointer to Github pull request: https://github.com/mozilla-b2g/gaia/pull/9634

* Use MimeMapper to identify filetype in Bluetooth App.
* Remove original MimeMapper from Bluetooth App.

Dominic,
Could you please help to review my pr? Thanks.
Attachment #747259 - Flags: review?(dkuo)

Comment 32

5 years ago
(In reply to Ian Liu [:ianliu] from comment #28)
> (In reply to qingluo.wang from comment #26)
> > Created attachment 746768 [details]
> > HCIDUMP
> > 
> > Hi:
> >   From the attached log, you can find the type is "application/ogg" during
> > data link layer,maybe this is the point of this issue,I hope that the log
> > can help you.
> 
> It's really helpful. We cannot identify that the file is belong to audio or
> video via filetype "application/ogg". And we cannot really open the file by
> Music/Video app before choosing an app to open. In general case, Video app
> is able to handle both of them. I would like to add filetype
> "application/ogg" corresponding to video in MimeMapper utility.
> 
> Change the flag tef? remissly. Recovery it.

I have a question about Bluetooth discovery,current, gecko will dispatch several events when one device is found,but Gaia just handle the first one,later update will be ignored,this will cause some issues(see bug869858),Is this a special design or other?thanks.
Flags: needinfo?(ffos-product)

Updated

5 years ago
Whiteboard: [triaged] → [triaged][status: waiting on product input from sandip]

Comment 33

5 years ago
For Comment 9: *.mp4, *.ogg, *.bmp formats need to be supported. 

CC: Marco: Have their been any changes to container handling recently for these types?
Flags: needinfo?(skamat)
Triage - leo+ per comment 33
blocking-b2g: leo? → leo+

Comment 35

5 years ago
Comment on attachment 747259 [details]
Pointer to Github pull request: https://github.com/mozilla-b2g/gaia/pull/9634

Ian,

This patch looks good, the usage of MimeMapper is the same as I implemented in bug 852477 for email so should be no problem, I am gald the bluetooth transfer app use MimeMapper as well because that's why I put it in shared/js.

And please wait for the patch of bug 869859 to land first or this patch will not be albe to solve the issue on opening *.ogg files.

r+ on commit: b6349e0c931d19612e9b6b522925c213d9ec37c1
Attachment #747259 - Flags: review?(dkuo) → review+
Thanks for Dominic's reviewing effort. And the MimeMapper is useful for opening a receiving file in Bluetooth app. If all of Gaia app use the it, the problem of opening file issue is able to slowly converge.

Since the pr is merged, we can close the issue now.
https://github.com/mozilla-b2g/gaia/commit/77bef8b2a65e4cc2d9aa2973282209562a8b6c48

note: Please make sure bug 869859 is landed in v1-train. Then, the issue could be fixed and landed in v1-train.
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
I was not able to uplift this bug to v1-train.  If this bug has dependencies which are not marked in this bug, please comment on this bug.  If this bug depends on patches that aren't approved for v1-train, we need to re-evaluate the approval.  Otherwise, if this is just a merge conflict, you might be able to resolve it with:

  git checkout v1-train
  git cherry-pick -x -m1 77bef8b2a65e4cc2d9aa2973282209562a8b6c48
  <RESOLVE MERGE CONFLICTS>
  git commit
(Reporter)

Comment 38

5 years ago
Hi KongMei:
   According to https://bugzilla.mozilla.org/show_bug.cgi?id=851995 comment#22 and comment#23,the patch will not be approved for v1.0.1,so please help to check it,thanks.
(In reply to John Ford [:jhford] -- If you expect a reply from me, use needsinfo? instead of CC from comment #37)
> I was not able to uplift this bug to v1-train.  If this bug has dependencies
> which are not marked in this bug, please comment on this bug.  If this bug
> depends on patches that aren't approved for v1-train, we need to re-evaluate
> the approval.  Otherwise, if this is just a merge conflict, you might be
> able to resolve it with:
> 
>   git checkout v1-train
>   git cherry-pick -x -m1 77bef8b2a65e4cc2d9aa2973282209562a8b6c48
>   <RESOLVE MERGE CONFLICTS>
>   git commit

John,
Thanks for your guidance. I have uplifed via a99ae3223fce2bdb31f2ae66da16f2f7f665a1cc.
$ git branch --contains a99ae3223fce2bdb31f2ae66da16f2f7f665a1cc
  v1-train
status-b2g18: --- → fixed

Updated

5 years ago
Flags: in-moztrap?

Comment 41

5 years ago
Dear Ian,
I saw your patch on v1.1, but I can't open the *.ogg file transfered by bluetooth. Could you have a look at this? Thank you very much.
Flags: needinfo?(iliu)

Comment 42

5 years ago
Dear Dale,
I found that the problem of can't open *.ogg file received by BT belongs to video app, so I needinfo you. here is some logs:

E/GeckoConsole(  639): Content JS LOG at app://video.gaiamobile.org/js/view.js:250 in showPlayer: video: player.src = blob:256239b6-7801-45d0-9787-220868eb52bb
E/GeckoConsole(  639): [JavaScript Warning: "Media resource blob:256239b6-7801-45d0-9787-220868eb52bb could not be decoded." {file: "app://video.gaiamobile.org/view.html" line: 0}]

And I will attach my ogg file for you to reproduce. Thanks a lot! I'll be right here waiting for your response :).
Flags: needinfo?(iliu) → needinfo?(dale)

Comment 43

5 years ago
Created attachment 775554 [details]
ogg file for reproduce

Comment 44

5 years ago
buri.blff@gmail.com, I think attachment 775554 [details] is a corrupted ogg video, are you able to play it on other platfroms like Ubuntu or Windows?
Yeh seeing it corrupted here too, clearing needinfo
Flags: needinfo?(dale)

Comment 46

5 years ago
Dear Dominic,
I can play that ogg file in my Android phone. What do you think?
Flags: needinfo?(dkuo)

Comment 47

5 years ago
xiaokang, I tried to play it on Windows, Ubuntu and OSX with VLC, but none of them is able to play attachment 775554 [details]. But then I truned to use Chrome to test and it works, so looks like Android/Chrome are the only platfrom that can play it, maybe it's because they used some unique codec from google, but this is only my guessing, I am not sure about it.

And if attachment 775554 [details] is not a mainstream ogg, we can file another bug to discuss about it then fix it, I believe what this issue was trying to resolve is already fixed, because I am able open/play the received files except attachment 775554 [details].
Flags: needinfo?(dkuo)

Updated

5 years ago
Flags: needinfo?(jhammink)

Comment 48

5 years ago
Dear Ian,
I test on

AU_LINUX_GECKO_ICS_STRAWBERRY.01.01.00.019.179
Firefox os  v1.1
Mozilla build ID:20130730070228 

after receiving video file from other phone, click the
"received file" item on notification bar, the video plays normally, but when
you press home key in the duration of the video playing, you will find a message box shows "can not open received file". And the same message showed if the file is image or music.

I think we should raise another pr for this. What do you think??
Flags: needinfo?(iliu)

Comment 49

5 years ago
It's already fixed by bug 893171.
Flags: needinfo?(iliu)
(Assignee)

Updated

5 years ago
Duplicate of this bug: 850544

Comment 51

4 years ago
Clearing the NI flag on this and adding a moztrap testcase instead.
Flags: needinfo?(jhammink)
Flags: in-moztrap?(jhammink)
Flags: in-moztrap?
You need to log in before you can comment on or make changes to this bug.