Open christianrockbryan opened 6 years ago
How did you do it on SDK to 6.x? For your information, I use SDK to 6.1.2.GA. I work on Background, but not Foreground. When operating on a Foreground, an error occurs as shown below and the Android app is shut down. Can you tell me what I need?
[ERROR] : SQLiteLog: (1) no such table: queue
[ERROR] : TiApplication: (pool-5-thread-1) [25948,69718] Sending event: exception on thread: pool-5-thread-1 msg:android.database.sqlite.SQLiteException: no such table: queue (code 1): , while compiling: INSERT INTO queue VALUES('0:1553479607371641%%02309570f9fd7ecd',1553479607366,'{"google.delivered_priority":"high","google.sent_time":1553479607366,"google.ttl":2419200,"google.original_priority":"high","title":"New notification","google.message_id":"0:1553479607371641%%02309570f9fd7ecd"}',0);; Titanium 6.1.2,2017/07/27 16:09,undefined
[ERROR] : TiApplication: android.database.sqlite.SQLiteException: no such table: queue (code 1): , while compiling: INSERT INTO queue VALUES('0:1553479607371641%%02309570f9fd7ecd',1553479607366,'{"google.delivered_priority":"high","google.sent_time":1553479607366,"google.ttl":2419200,"google.original_priority":"high","title":"New notification","google.message_id":"0:1553479607371641%%02309570f9fd7ecd"}',0);
[ERROR] : TiApplication: at android.database.sqlite.SQLiteConnection.nativePrepareStatement(Native Method)
[ERROR] : TiApplication: at android.database.sqlite.SQLiteConnection.acquirePreparedStatement(SQLiteConnection.java:893)
[ERROR] : TiApplication: at android.database.sqlite.SQLiteConnection.prepare(SQLiteConnection.java:504)
[ERROR] : TiApplication: at android.database.sqlite.SQLiteSession.prepare(SQLiteSession.java:726)
[ERROR] : TiApplication: at android.database.sqlite.SQLiteProgram.
I just started using ti.fcm but I could only get it to work if I changed my SDK to 6.3.0. Will there be support coming for v7.x?
Also, I am able get a token successfully and send a notification to it. When my app is closed, my Android phone receives the message correctly.
When the app is open, I get the following errors:
[ERROR] : SQLiteLog: (1) no such table: queue [ERROR] : TiApplication: (pool-5-thread-1) [63897,69164] Sending event: exception on thread: pool-5-thread-1 msg:android.database.sqlite.SQLiteException: no such table: queue (code 1): , while compiling: INSERT INTO queue VALUES('0:1524062166078827%d57dd6cad57dd6ca',1524062166074,'{"google.sent_time":1524062166074,"google.ttl":2419200,"google.message_id":"0:1524062166078827%d57dd6cad57dd6ca","collapse_key":"com.marckrecycling.app"}',0); [ERROR] : TiApplication: ################################################################# [ERROR] : TiApplication: Error Code : 1 (SQLITE_ERROR) [ERROR] : TiApplication: Caused By : SQL(query) error or missing database. [ERROR] : TiApplication: (no such table: queue (code 1): , while compiling: INSERT INTO queue VALUES('0:1524062166078827%d57dd6cad57dd6ca',1524062166074,'{"google.sent_time":1524062166074,"google.ttl":2419200,"google.message_id":"0:1524062166078827%d57dd6cad57dd6ca","collapse_key":"com.marckrecycling.app"}',0);) [ERROR] : TiApplication: #################################################################; Titanium 6.3.0,2017/10/31 18:13,undefined [ERROR] : TiApplication: android.database.sqlite.SQLiteException: no such table: queue (code 1): , while compiling: INSERT INTO queue VALUES('0:1524062166078827%d57dd6cad57dd6ca',1524062166074,'{"google.sent_time":1524062166074,"google.ttl":2419200,"google.message_id":"0:1524062166078827%d57dd6cad57dd6ca","collapse_key":"com.marckrecycling.app"}',0); [ERROR] : TiApplication: ################################################################# [ERROR] : TiApplication: Error Code : 1 (SQLITE_ERROR) [ERROR] : TiApplication: Caused By : SQL(query) error or missing database. [ERROR] : TiApplication: (no such table: queue (code 1): , while compiling: INSERT INTO queue VALUES('0:1524062166078827%d57dd6cad57dd6ca',1524062166074,'{"google.sent_time":1524062166074,"google.ttl":2419200,"google.message_id":"0:1524062166078827%d57dd6cad57dd6ca","collapse_key":"com.marckrecycling.app"}',0);) [ERROR] : TiApplication: ################################################################# [ERROR] : TiApplication: at android.database.sqlite.SQLiteConnection.nativePrepareStatement(Native Method) [ERROR] : TiApplication: at android.database.sqlite.SQLiteConnection.acquirePreparedStatement(SQLiteConnection.java:1008) [ERROR] : TiApplication: at android.database.sqlite.SQLiteConnection.prepare(SQLiteConnection.java:573) [ERROR] : TiApplication: at android.database.sqlite.SQLiteSession.prepare(SQLiteSession.java:588) [ERROR] : TiApplication: at android.database.sqlite.SQLiteProgram.(SQLiteProgram.java:59)
[ERROR] : TiApplication: at android.database.sqlite.SQLiteStatement.(SQLiteStatement.java:31)
[ERROR] : TiApplication: at android.database.sqlite.SQLiteDatabase.executeSql(SQLiteDatabase.java:1986)
[ERROR] : TiApplication: at android.database.sqlite.SQLiteDatabase.execSQL(SQLiteDatabase.java:1917)
[ERROR] : TiApplication: at ti.fcm.GCMQueue.insertMessage(GCMQueue.java:36)
[ERROR] : TiApplication: at ti.fcm.MyGcmListenerService.onMessageReceived(MyGcmListenerService.java:37)
[ERROR] : TiApplication: at com.google.android.gms.gcm.GcmListenerService.handleIntent(Unknown Source)
[ERROR] : TiApplication: at com.google.firebase.iid.zzc.run(Unknown Source)
[ERROR] : TiApplication: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
[ERROR] : TiApplication: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
[ERROR] : TiApplication: at java.lang.Thread.run(Thread.java:762)
What I can go get around these?
Thanks! Bryan