Closed Bug 1048122 Opened 10 years ago Closed 10 years ago

Get stuck on the export screen when exporting contacts to SIM card that is full

Categories

(Firefox OS Graveyard :: RIL, defect)

ARM
Gonk (Firefox OS)
defect
Not set
major

Tracking

(b2g-v1.3T affected)

RESOLVED DUPLICATE of bug 1022490
Tracking Status
b2g-v1.3T --- affected

People

(Reporter: na.hao, Assigned: edgar)

References

Details

Attachments

(2 files)

Description:
Use a 64k USIM card that is already full,export an new contact to this SIM card,it will be stuck on the "Export to SIM" screen. 

Repro Steps:
1)  Tap on the "Contacts app" icon.
2)  Tap on the "Gear" icon to open settings.
3)  Tap on "Export Contacts".
4)  Tap on the "SIM card" option.
5)  Tap on a contact newly added and then tap on "Export". 

Actual:
It stucks on the "Export to SIM" screen and will have to tap home close the app.

Expected:
Show "SIM Card is full" normally.
Summary: Get stuck on the export screen when exporting contacts to the specific SIM card that is full → Get stuck on the export screen when exporting contacts to SIM card that is full
neither request.onsuccess nor request.onerror is executed after "var request = icc.updateContact('adn', theContact)" , so the finishCallback(actually the _doHandleResult()) is not called back,and no error message is shown.

gaia/apps/communications/contacts/js/export/sim.js:

var _doExport = function _doExport(step, finishCallback) {
      ... ...
var next = function next(success, contact) {
      ... ...
      _doExport(step, finishCallback);
    };
... ...

var request = icc.updateContact('adn', theContact);
    request.onsuccess = function onsuccess() {
     ... ...
      if (idToUpdate) {
        next(true, theContact);
        return;
      }
      // Now it is needed to save the provided id in case we don't have one
      var iccContact = request.result;
      _updateContactSimSource(theContact, iccContact,
                              function export_update_success() {
        next(true, theContact);
      }, function export_update_error(err) {
          window.console.error('Error while updating: ', err.name);
          next(true, theContact);
      });
    };

    request.onerror = function onerror(e) {
      var error = e.target.error;
      ... ...
      if (errorName !== 'GenericError') {
        finishCallback({
          'reason': errorName
        }, exported.length, ERRORS[error.name]);
      }
      else {
        next(false, theContact);
      }
    };
when SIM card is not full (160 contacts) ,select 900 contacts to export,it shows the "SIM Card is full" message when only 20 contacts being exported,actually it only 180 contacts in SIM card.

so whether SIM card is full or not ,there are some problems about the request for updateContact when export excessive contacts to the SIM card.
This is specific to exporting contacts to China Unicom USIM card.

Edgar, Could you take a look, thanks.
Flags: needinfo?(echen)
Hi na.hao and Shiwei:

Could you help to provide the log for analysis?

Thank you.
Flags: needinfo?(shiwei.zhang)
Flags: needinfo?(na.hao)
Flags: needinfo?(echen)
It's the log for stuck on "Export to SIM" when the SIM card is full,and to export new contacts to it.
(In reply to Na Hao from comment #5)
> Created attachment 8467618 [details]
> log for stuck on "Export to SIM"
> 
> It's the log for stuck on "Export to SIM" when the SIM card is full,and to
> export new contacts to it.

It seems something wrong when handling "NoFreeRecodFound",

10-13 09:24:30.240 I/Gecko   (   86): RIL Worker: [0] NoFreeRecordFound
10-13 09:24:30.260 I/Gecko   (   86): RIL Worker: Parcel handling threw TypeError: this is null
10-13 09:24:30.260 I/Gecko   (   86): findFreeRecordId@resource://gre/modules/ril_worker.js:13923
10-13 09:24:30.260 I/Gecko   (   86): callback@resource://gre/modules/ril_worker.js:12454
10-13 09:24:30.260 I/Gecko   (   86): processICCIOReadRecord@resource://gre/modules/ril_worker.js:11869
10-13 09:24:30.260 I/Gecko   (   86): ICC_COMMAND_READ_RECORD@resource://gre/modules/ril_worker.js:11918
10-13 09:24:30.260 I/Gecko   (   86): processICCIO@resource://gre/modules/ril_worker.js:11751
10-13 09:24:30.260 I/Gecko   (   86): REQUEST_SIM_IO@resource://gre/modules/ril_worker.js:5504
10-13 09:24:30.260 I/Gecko   (   86): handleParcel@resource://gre/modules/ril_worker.js:5142
10-13 09:24:30.260 I/Gecko   (   86): processParcel@resource://gre/modules/ril_worker.js:160
10-13 09:24:30.260 I/Gecko   (   86): processIncoming@blob:7a3274b8-169b-40e0-82c2-eeda56917260:536
10-13 09:24:30.260 I/Gecko   (   86): handleRilMessage@resource://gre/modules/ril_worker.js:14498
10-13 09:24:30.260 I/Gecko   (   86): onRILMessage@resource://gre/modules/ril_worker.js:14543
Flags: needinfo?(shiwei.zhang)
Flags: needinfo?(na.hao)
when select lots of contacts to export,it can be reproduced. when select a small amount of (for example 30)to export ,it works normally.
(In reply to Na Hao from comment #5)
> Created attachment 8467618 [details]
> log for stuck on "Export to SIM"
> 
> It's the log for stuck on "Export to SIM" when the SIM card is full,and to
> export new contacts to it.

Could you share the build information to me? (Gecko version and Gaia version)
Thank you.
Component: Gaia::Contacts → RIL
(In reply to Edgar Chen [:edgar][:echen] from comment #8)
> Could you share the build information to me? (Gecko version and Gaia version)
> Thank you.

"gaia" remote="mozillaorg" revision="1f9e1a53339030d1db9beb41f3873847ddf2d587" 
"gecko" remote="mozillaorg" revision="ad0ac6ff6d4e1ce050da759668c25d22ecc5ba5b"
(In reply to Edgar Chen [:edgar][:echen] from comment #6)
> (In reply to Na Hao from comment #5)
> > Created attachment 8467618 [details]
> > log for stuck on "Export to SIM"
> > 
> > It's the log for stuck on "Export to SIM" when the SIM card is full,and to
> > export new contacts to it.
> 
> It seems something wrong when handling "NoFreeRecodFound",
> 
> 10-13 09:24:30.240 I/Gecko   (   86): RIL Worker: [0] NoFreeRecordFound
> 10-13 09:24:30.260 I/Gecko   (   86): RIL Worker: Parcel handling threw
> TypeError: this is null
> 10-13 09:24:30.260 I/Gecko   (   86):
> findFreeRecordId@resource://gre/modules/ril_worker.js:13923
> 10-13 09:24:30.260 I/Gecko   (   86):
> callback@resource://gre/modules/ril_worker.js:12454
> 10-13 09:24:30.260 I/Gecko   (   86):
> processICCIOReadRecord@resource://gre/modules/ril_worker.js:11869
> 10-13 09:24:30.260 I/Gecko   (   86):
> ICC_COMMAND_READ_RECORD@resource://gre/modules/ril_worker.js:11918
> 10-13 09:24:30.260 I/Gecko   (   86):
> processICCIO@resource://gre/modules/ril_worker.js:11751
> 10-13 09:24:30.260 I/Gecko   (   86):
> REQUEST_SIM_IO@resource://gre/modules/ril_worker.js:5504
> 10-13 09:24:30.260 I/Gecko   (   86):
> handleParcel@resource://gre/modules/ril_worker.js:5142
> 10-13 09:24:30.260 I/Gecko   (   86):
> processParcel@resource://gre/modules/ril_worker.js:160
> 10-13 09:24:30.260 I/Gecko   (   86):
> processIncoming@blob:7a3274b8-169b-40e0-82c2-eeda56917260:536
> 10-13 09:24:30.260 I/Gecko   (   86):
> handleRilMessage@resource://gre/modules/ril_worker.js:14498
> 10-13 09:24:30.260 I/Gecko   (   86):
> onRILMessage@resource://gre/modules/ril_worker.js:14543

Hmm, I found this issue before and already fixed it in bug 1022490.
Assignee: nobody → echen
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → DUPLICATE
Blocks: 1157082
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: