javascript - Cannot open the event or launch the Calendar app after create an event programming? -
i'm using https://www.npmjs.com/package/cordova-plugin-calendar cordova/phonegap plugin create events. events created (i tested in emulator). clicking event in calendar crash calendar app. following debug output.
i tried stop calendar app , clear data , didn't help. when sideloading phone, calendar app cannot launch @ all. bug of calendar app since data written 3rd party plugins can crush app?
the following javascript code used create events.
$scope.addcalendar = function (title, eventlocation, notes, startdate, enddate) {//, success, error) { //var success = function (message) { console.log("success: " + json.stringify(message)); }; //var error = function (message) { console.error("error: " + message); }; //window.plugins.calendar.createcalendar("test calendar", success, error); var s = new date(startdate); var e = new date(enddate); window.plugins.calendar.createevent(title, eventlocation, notes, s, e, function (result) { console.log('event created.'); }, function (err) { console.error("there error "+ err); } ); //, success, error); };
debug output:
i/activitymanager( 1500): start u0 {act=android.intent.action.view dat=content://com.android.calendar/events/3 flg=0x20020000 cmp=com.android.calendar/.eventinfoactivity (has extras)} uid 10018 on display 0 i/inputdispatcher( 1500): dropping event because there no touchable window @ (869, 499). i/inputdispatcher( 1500): dropping event because there no touchable window @ (869, 499). i/webviewfactory( 5558): loading com.android.webview version 37 (2882263-x86) (code 100007) i/libraryloader( 5558): loading: webviewchromium i/libraryloader( 5558): time load native libraries: 1 ms (timestamps 5605-5606) i/libraryloader( 5558): expected native library version number "",actual native library version number "" v/webviewchromiumfactoryprovider( 5558): binding chromium main looper looper (main, tid 1) {87cf21c} i/libraryloader( 5558): expected native library version number "",actual native library version number "" i/chromium( 5558): [info:library_loader_hooks.cc(106)] chromium logging enabled: level = 0, default verbosity = 0 i/browserstartupcontroller( 5558): initializing chromium process, renderers=0 w/art ( 5558): attempt remove local handle scope entry irt, ignoring w/chromium( 5558): [warning:resource_bundle.cc(315)] locale_file_path.empty() i/chromium( 5558): [info:aw_browser_main_parts.cc(63)] load apk succesful, fd=42 off=46092 len=2953 i/chromium( 5558): [info:aw_browser_main_parts.cc(78)] loading webviewchromium.pak from, fd:43 off:228796 len:643667 w/audiomanagerandroid( 5558): requires bluetooth permission i/inputdispatcher( 1500): dropping event because there no touchable window @ (869, 499). i/inputdispatcher( 1500): dropping event because there no touchable window @ (869, 499). i/activitymanager( 1500): displayed com.android.calendar/.eventinfoactivity: +251ms e/databaseutils( 2131): writing exception parcel e/databaseutils( 2131): java.lang.illegalargumentexception: bind value @ index 2 null e/databaseutils( 2131): @ android.database.sqlite.sqliteprogram.bindstring(sqliteprogram.java:164) e/databaseutils( 2131): @ android.database.sqlite.sqliteprogram.bindallargsasstrings(sqliteprogram.java:200) e/databaseutils( 2131): @ android.database.sqlite.sqlitedirectcursordriver.query(sqlitedirectcursordriver.java:47) e/databaseutils( 2131): @ android.database.sqlite.sqlitedatabase.rawquerywithfactory(sqlitedatabase.java:1316) e/databaseutils( 2131): @ android.database.sqlite.sqlitequerybuilder.query(sqlitequerybuilder.java:400) e/databaseutils( 2131): @ android.database.sqlite.sqlitequerybuilder.query(sqlitequerybuilder.java:333) e/databaseutils( 2131): @ com.android.providers.calendar.calendarprovider2.query(calendarprovider2.java:1062) e/databaseutils( 2131): @ com.android.providers.calendar.calendarprovider2.queryinternal(calendarprovider2.java:1033) e/databaseutils( 2131): @ com.android.providers.calendar.calendarprovider2.query(calendarprovider2.java:839) e/databaseutils( 2131): @ android.content.contentprovider.query(contentprovider.java:950) e/databaseutils( 2131): @ android.content.contentprovider$transport.query(contentprovider.java:210) e/databaseutils( 2131): @ android.content.contentprovidernative.ontransact(contentprovidernative.java:112) e/databaseutils( 2131): @ android.os.binder.exectransact(binder.java:446) w/asyncquery( 5558): java.lang.illegalargumentexception: bind value @ index 2 null d/androidruntime( 5558): shutting down vm e/androidruntime( 5558): fatal exception: main e/androidruntime( 5558): process: com.android.calendar, pid: 5558 e/androidruntime( 5558): java.lang.nullpointerexception: attempt invoke interface method 'boolean android.database.cursor.movetofirst()' on null object reference e/androidruntime( 5558): @ com.android.calendar.eventinfofragment$queryhandler.onquerycomplete(eventinfofragment.java:536) e/androidruntime( 5558): @ com.android.calendar.asyncqueryservice.handlemessage(asyncqueryservice.java:412) e/androidruntime( 5558): @ android.os.handler.dispatchmessage(handler.java:102) e/androidruntime( 5558): @ android.os.looper.loop(looper.java:135) e/androidruntime( 5558): @ android.app.activitythread.main(activitythread.java:5221) e/androidruntime( 5558): @ java.lang.reflect.method.invoke(native method) e/androidruntime( 5558): @ java.lang.reflect.method.invoke(method.java:372) e/androidruntime( 5558): @ com.android.internal.os.zygoteinit$methodandargscaller.run(zygoteinit.java:899) e/androidruntime( 5558): @ com.android.internal.os.zygoteinit.main(zygoteinit.java:694) w/activitymanager( 1500): force finishing activity com.android.calendar/.eventinfoactivity w/activitymanager( 1500): force finishing activity com.android.calendar/.allinoneactivity d/dropboxentryaddedchimeraservice( 2216): user not opted-in usage & diagnostics. i/openglrenderer( 1500): initialized egl, version 1.4 w/activitymanager( 1500): activity pause timeout activityrecord{308c7753 u0 com.android.calendar/.eventinfoactivity t33 f} i/process ( 5558): sending signal. pid: 5558 sig: 9 w/audiotrack( 1500): audio_output_flag_fast denied client i/windowstate( 1500): win death: window{251673fd u0 com.android.calendar/com.android.calendar.eventinfoactivity} w/libprocessgroup( 1500): failed open /acct/uid_10018/pid_5558/cgroup.procs: no such file or directory i/activitymanager( 1500): process com.android.calendar (pid 5558) has died i/windowstate( 1500): win death: window{2fede9b6 u0 com.android.calendar/com.android.calendar.allinoneactivity} w/inputmethodmanagerservice( 1500): got remoteexception sending setactive(false) notification pid 5558 uid 10018
Comments
Post a Comment