Comments (6)
Could you please send logs from XCode console? I've tried the setTags code and everything worked fine with success callback. Please note that status variable will be null.
Also don't forget to create tag in the control panel before setting it! Also City is default tag, you might not want to modify it.
from pushwoosh-phonegap-plugin.
Thanks for the reply @shaders
I don't use XCode. I use Eclipse, the app is based in Ionic Framework then built with Cordova.
When i do this,
//settings tags
pushNotification.setTags({Clientid:"hello"},
function(status) {
console.warn('setTags success '+status);
},
function(status) {
console.warn('setTags failed '+status);
});
I get "setTags failed Invalid action" in console log. But when i check my Pushwoosh backend, i notice that the tag is set.
from pushwoosh-phonegap-plugin.
That is super weird. Just tried Android Cordova sample and everything was fine. Can you post logs?
from pushwoosh-phonegap-plugin.
Hello,
I'm getting the same issues with the setTags method (Pushwoosh plugin
from
https://github.com/Pushwoosh/pushwoosh-phonegap-3.0-plugin) in my
Cordova app in Android (I could not check in iOS yet) :
with Android 4.2.1 :
I can't get the setTags method done (executed right after
registerDevice succesful) :
Error MSG retrieved :
09-05 17:56:04.425: W/Pushwoosh: Request manager(15584): Try To sent:
setTags
09-05 17:56:04.435: E/Pushwoosh: Request manager(15584): at
com.arellomobile.android.push.DeviceFeature2_5.sendTags(Unknown
Source)
09-05 17:56:04.435: E/Pushwoosh: Request manager(15584): at
com.arellomobile.android.push.PushManager.sendTagsFromBG(Unknown
Source)
09-05 17:56:04.435: E/Pushwoosh: Request manager(15584): at
com.pushwoosh.plugin.pushnotifications.PushNotifications.internalSendTags(PushNotifications.java:325)
09-05 17:56:04.445: W/System.err(15584): at
com.arellomobile.android.push.PushManager.sendTagsFromBG(Unknown
Source)
09-05 17:56:04.445: W/System.err(15584): at
com.pushwoosh.plugin.pushnotifications.PushNotifications.internalSendTags(PushNotifications.java:325)
09-05 17:56:04.455: W/System.err(15584): at
com.arellomobile.android.push.DeviceFeature2_5.sendTags(Unknown
Source)
09-05 17:56:04.465: W/PluginManager(15584): THREAD WARNING: exec()
call to PushNotification.setTags blocked the main thread for 39ms.
Plugin should use CordovaInterface.getThreadPool().
09-05 17:56:04.465: W/Web Console(15584): failed to set tags "Invalid
action" at file:///android_asset/www/js/openways/Pushwoosh.js:100
Same code is getting a different result :
Android 4.4.2 :
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): ERROR:
http://cp.pushwoosh.com/json/1.3/applicationOpen. Response = null
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193):
java.io.FileNotFoundException:
http://cp.pushwoosh.com/json/1.3/applicationOpen
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
com.android.okhttp.internal.http.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:186)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
com.arellomobile.android.push.request.RequestManager.makeRequest(Unknown
Source)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
com.arellomobile.android.push.request.RequestManager.sendRequest(Unknown
Source)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
com.arellomobile.android.push.DeviceFeature2_5.sendAppOpen(Unknown
Source)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
com.arellomobile.android.push.PushManager$8$1.doWork(Unknown Source)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
com.arellomobile.android.push.utils.WorkerTask.doInBackground(Unknown
Source)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
com.arellomobile.android.push.utils.WorkerTask.doInBackground(Unknown
Source)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
android.os.AsyncTask$2.call(AsyncTask.java:288)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
java.util.concurrent.FutureTask.run(FutureTask.java:237)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)
09-05 18:35:13.331: E/Pushwoosh: Request manager(10193): at
java.lang.Thread.run(Thread.java:841)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): ERROR:
http://cp.pushwoosh.com/json/1.3/setTags. Response = null
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193):
java.io.FileNotFoundException:
http://cp.pushwoosh.com/json/1.3/setTags
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
com.android.okhttp.internal.http.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:186)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
com.arellomobile.android.push.request.RequestManager.makeRequest(Unknown
Source)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
com.arellomobile.android.push.request.RequestManager.sendRequest(Unknown
Source)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
com.arellomobile.android.push.DeviceFeature2_5.sendTags(Unknown
Source)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
com.arellomobile.android.push.PushManager.sendTagsFromBG(Unknown
Source)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
com.pushwoosh.plugin.pushnotifications.PushNotifications.internalSendTags(PushNotifications.java:325)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
com.pushwoosh.plugin.pushnotifications.PushNotifications.execute(PushNotifications.java:382)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
org.apache.cordova.CordovaPlugin.execute(CordovaPlugin.java:65)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
org.apache.cordova.PluginManager.execHelper(PluginManager.java:242)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
org.apache.cordova.PluginManager.exec(PluginManager.java:227)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
org.apache.cordova.ExposedJsApi.exec(ExposedJsApi.java:53)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
com.android.org.chromium.base.SystemMessageHandler.nativeDoRunLoopOnce(Native
Method)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
com.android.org.chromium.base.SystemMessageHandler.handleMessage(SystemMessageHandler.java:27)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
android.os.Handler.dispatchMessage(Handler.java:102)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
android.os.Looper.loop(Looper.java:157)
09-05 18:35:13.492: E/Pushwoosh: Request manager(10193): at
android.os.HandlerThread.run(HandlerThread.java:61)
09-05 18:35:13.492: W/System.err(10193):
com.arellomobile.android.push.exception.PushWooshException:
java.io.FileNotFoundException:
http://cp.pushwoosh.com/json/1.3/setTags
09-05 18:35:13.492: W/System.err(10193): at
com.arellomobile.android.push.PushManager.sendTagsFromBG(Unknown
Source)
09-05 18:35:13.492: W/System.err(10193): at
com.pushwoosh.plugin.pushnotifications.PushNotifications.internalSendTags(PushNotifications.java:325)
09-05 18:35:13.492: W/System.err(10193): at
com.pushwoosh.plugin.pushnotifications.PushNotifications.execute(PushNotifications.java:382)
09-05 18:35:13.502: W/System.err(10193): at
org.apache.cordova.CordovaPlugin.execute(CordovaPlugin.java:65)
09-05 18:35:13.502: W/System.err(10193): at
org.apache.cordova.PluginManager.execHelper(PluginManager.java:242)
09-05 18:35:13.502: W/System.err(10193): at
org.apache.cordova.PluginManager.exec(PluginManager.java:227)
09-05 18:35:13.502: W/System.err(10193): at
org.apache.cordova.ExposedJsApi.exec(ExposedJsApi.java:53)
09-05 18:35:13.502: W/System.err(10193): at
com.android.org.chromium.base.SystemMessageHandler.nativeDoRunLoopOnce(Native
Method)
09-05 18:35:13.502: W/System.err(10193): at
com.android.org.chromium.base.SystemMessageHandler.handleMessage(SystemMessageHandler.java:27)
09-05 18:35:13.512: W/System.err(10193): at
android.os.Handler.dispatchMessage(Handler.java:102)
09-05 18:35:13.512: W/System.err(10193): at
android.os.Looper.loop(Looper.java:157)
09-05 18:35:13.512: W/System.err(10193): at
android.os.HandlerThread.run(HandlerThread.java:61)
09-05 18:35:13.512: W/System.err(10193): Caused by:
java.io.FileNotFoundException:
http://cp.pushwoosh.com/json/1.3/setTags
09-05 18:35:13.512: W/System.err(10193): at
com.android.okhttp.internal.http.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:186)
09-05 18:35:13.522: W/System.err(10193): at
com.arellomobile.android.push.request.RequestManager.makeRequest(Unknown
Source)
09-05 18:35:13.522: W/System.err(10193): at
com.arellomobile.android.push.request.RequestManager.sendRequest(Unknown
Source)
09-05 18:35:13.522: W/System.err(10193): at
com.arellomobile.android.push.DeviceFeature2_5.sendTags(Unknown
Source)
09-05 18:35:13.522: W/System.err(10193): ... 12 more
09-05 18:35:13.522: W/PluginManager(10193): THREAD WARNING: exec()
call to PushNotification.setTags blocked the main thread for 60219ms.
Plugin should use CordovaInterface.getThreadPool().
Thank you by advance,
from pushwoosh-phonegap-plugin.
Does it still happening?
from pushwoosh-phonegap-plugin.
It seems to be resolved on Android 4.4.2.
Anyway, it's stilll returning Invalid action for Android 4.1.2 BUT it's working (I can send and receive pushes with appropriate tags).
This first issue can be solved.
Moreover, I have some issues for sending pushes from time to time:
createMessage request will end on timeout error (Ajax request).
And then it will work, and not working again, etc etc.
from pushwoosh-phonegap-plugin.
Related Issues (20)
- Cordova build android failed: Execution failed for task ':app:checkDebugAarMetadata'. HOT 3
- 8.3.5 Unable to build for iOS HOT 2
- 8.3.6 Unable to build for Android HOT 2
- iOS Build failed on 8.3.6 There is no XCFramework found HOT 4
- Android build fails with cordova-android version 11 and targetSdkVersion >= 31 HOT 22
- Android BUILD FAILED version 8.3.6 HOT 1
- Binary files not allowed in bundle HOT 5
- Build errors for version 8.3.8 HOT 3
- Ionic Capacitor cannot listen to push-receive and push-notification events HOT 5
- Android "heads-up notifications" not showing up even with "android_priority" set to 2 HOT 2
- Android issue RegisterForPushNotificationsResultData with 8.3.10 version HOT 2
- [Android] Tap on Notification doesn't open the app. HOT 1
- Application does not define permission com.google.android.c2dm.permission.RECEIVE HOT 2
- FcmRegistrarWorker] FCM registration error: Failed to retrieve token. Is firebase configured correctly? HOT 4
- 'Pushwoosh/Pushwoosh.h' file not found HOT 5
- 'Pushwoosh/Pushwoosh.h' file not found cordova ios 6.2.0 and pushwoosh plugin 8.3.13 HOT 2
- Capacitor 5 support HOT 4
- Build error with cordova-android@12 HOT 3
- iOS: Listeners conflict with @capacitor/local-notifications HOT 10
- Q: Any way to receive a silent push in a killed app HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pushwoosh-phonegap-plugin.