Return-Path: X-Original-To: apmail-cordova-issues-archive@minotaur.apache.org Delivered-To: apmail-cordova-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 66CB418B14 for ; Sun, 15 Nov 2015 16:33:11 +0000 (UTC) Received: (qmail 64630 invoked by uid 500); 15 Nov 2015 16:33:11 -0000 Delivered-To: apmail-cordova-issues-archive@cordova.apache.org Received: (qmail 64600 invoked by uid 500); 15 Nov 2015 16:33:11 -0000 Mailing-List: contact issues-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@cordova.apache.org Received: (qmail 64575 invoked by uid 99); 15 Nov 2015 16:33:11 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 15 Nov 2015 16:33:11 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 112582C1F5F for ; Sun, 15 Nov 2015 16:33:11 +0000 (UTC) Date: Sun, 15 Nov 2015 16:33:11 +0000 (UTC) From: "Rony Cohen (JIRA)" To: issues@cordova.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CB-9628) cordova-plugin-contacts crashes the app MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CB-9628?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15005964#comment-15005964 ] Rony Cohen commented on CB-9628: -------------------------------- Hello [~vladimir.kotikov] I re-installed last stable version of the plugin. cordova-plugin-contacts 1.1.0 "Contacts" It's working but when I choose : navigator.contacts.fieldType.phoneNumbers in the options.desiredFields I get this error : Error in Success callbackId: Contacts598408154 : SyntaxError: Unexpected token u cordova.js:312 I tried with the last dev version of the plugin. cordova-plugin-contacts 1.1.1-dev "Contacts" I have this error : ReferenceError: ContactFindOptions is not defined The plugin is unstable I think. > cordova-plugin-contacts crashes the app > --------------------------------------- > > Key: CB-9628 > URL: https://issues.apache.org/jira/browse/CB-9628 > Project: Apache Cordova > Issue Type: Bug > Components: Plugin Contacts > Affects Versions: 5.2.0 > Environment: Smartphone android One plus One : device product:bacon model:A0001 device:A0001 > Reporter: Rony Cohen > Assignee: Vladimir Kotikov > Labels: Android, android, triaged > > I encounter an aleatory crash with my Cordova Application on android smartphone One plus One (device product:bacon model:A0001 device:A0001). > Is there any error on my code ? Can you tell me what I could do ? > Thank you. > Here is the AngularJS function : > getAllContacts : function(){ > var deferred = $q.defer(); > > var onSuccess = function(contacts) { > deferred.resolve(contacts); > }; > var onError = function(contactError) { > deferred.reject(contactError); > }; > > var options = new ContactFindOptions(); > options.filter = ""; > options.multiple = true; > var fields = ["*"]; > > navigator.contacts.find(fields, onSuccess, onError, options); > > > return deferred.promise; > }, > ***************** > Here is the crash LOG I got from ADB LOGCAT: > ***************** > I/chromium(10453): [INFO:CONSOLE(95)] "getContacts", source: file:///android_asset/www/app/components/contacts/ContactsService.js (95) > > D/LBSSystemMonitorService( 758): handleMessage what - 4 > > D/Wiper_jni( 758): Send Network Location. > > I/chromium(10453): [INFO:CONSOLE(22)] "$ionicView.enter ListContactsCtrl", source: file:///android_asset/www/app/components/contacts/importContactsController.js (22) > > I/chromium(10453): [INFO:CONSOLE(5)] "homeCtrl", source: file:///android_asset/www/app/components/home/homeController.js (5) > > W/CursorWindow(17276): Window is full: requested allocation 168 bytes, free space 75 bytes, window size 2097152 bytes > > I/art ( 758): Explicit concurrent mark sweep GC freed 186688(8MB) AllocSpace objects, 9(144KB) LOS objects, 28% free, 40MB/56MB, paused > 4.019ms total 193.548ms > > D/HeadsetStateMachine( 3762): Disconnected process message: 10, size: 0 > > W/ActivityManager( 758): getRunningAppProcesses: caller 10086 does not hold REAL_GET_TASKS; limiting output > > I/art (17276): Explicit concurrent mark sweep GC freed 36472(2MB) AllocSpace objects, 0(0B) LOS objects, 40% free, 19MB/33MB, paused > 2.271ms total 58.172ms > > W/ActivityManager( 758): getRunningAppProcesses: caller 10103 does not hold REAL_GET_TASKS; limiting output > > D/HeadsetStateMachine( 3762): Disconnected process message: 10, size: 0 > > E/CursorWindow(10453): Could not create CursorWindow from Parcel due to error -12. > > --------- beginning of crash > > E/AndroidRuntime(10453): FATAL EXCEPTION: pool-3-thread-3 > > E/AndroidRuntime(10453): Process: net.myapp.app, PID: 10453 > > E/AndroidRuntime(10453): android.database.CursorWindowAllocationException: Cursor window could not be created from binder. > > E/AndroidRuntime(10453): at android.database.CursorWindow.(CursorWindow.java:137) > > E/AndroidRuntime(10453): at android.database.CursorWindow.(CursorWindow.java:42) > > E/AndroidRuntime(10453): at android.database.CursorWindow$1.createFromParcel(CursorWindow.java:685) > > E/AndroidRuntime(10453): at android.database.CursorWindow$1.createFromParcel(CursorWindow.java:683) > > E/AndroidRuntime(10453): at android.database.BulkCursorDescriptor.readFromParcel(BulkCursorDescriptor.java:75) > > E/AndroidRuntime(10453): at android.database.BulkCursorDescriptor$1.createFromParcel(BulkCursorDescriptor.java:34) > > E/AndroidRuntime(10453): at android.database.BulkCursorDescriptor$1.createFromParcel(BulkCursorDescriptor.java:30) > > E/AndroidRuntime(10453): at android.content.ContentProviderProxy.query(ContentProviderNative.java:424) > > E/AndroidRuntime(10453): at android.content.ContentResolver.query(ContentResolver.java:478) > > E/AndroidRuntime(10453): at android.content.ContentResolver.query(ContentResolver.java:422) > > E/AndroidRuntime(10453): at org.apache.cordova.contacts.ContactAccessorSdk5.photoQuery(ContactAccessorSdk5.java:910) > > E/AndroidRuntime(10453): at org.apache.cordova.contacts.ContactAccessorSdk5.populateContactArray(ContactAccessorSdk5.java:439) > > E/AndroidRuntime(10453): at org.apache.cordova.contacts.ContactAccessorSdk5.search(ContactAccessorSdk5.java:271) > > E/AndroidRuntime(10453): at org.apache.cordova.contacts.ContactManager$1.run(ContactManager.java:93) > > E/AndroidRuntime(10453): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112) > > E/AndroidRuntime(10453): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587) > > E/AndroidRuntime(10453): at java.lang.Thread.run(Thread.java:818) > > W/DropBoxManagerService( 758): Dropping: data_app_crash (1587 > 0 bytes) > > D/LogFetchServiceManager( 4073): Received entry added > > W/ActivityManager( 758): Force finishing activity 1 net.myapp.app/.MainActivity > > D/OpenGLRenderer( 758): Use EGL_SWAP_BEHAVIOR_PRESERVED: true -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org For additional commands, e-mail: issues-help@cordova.apache.org