Closed kris1803 closed 2 years ago
Hi @kris1803, Thanks for your report and for the suggested workaround.
Are you able to get our SDK working properly in Expo? Last we checked, HeadlessJS tasks were broken in Expo. Please confirm background notification delivery works on Android with Expo and we will resolve these warnings.
Yes, headless tasks work (or if you talk about pushy register and listen more precisely), so app can wake up when it was killed to receive notification. So it works properly, but meanwhile I didn't test subscriptions to notifications. I must precise that I use Expokit, it is a hybrid between expo and bare react native.
Hi @kris1803, Thanks for confirming.
This warning has now been resolved in https://github.com/pushy/pushy-react-native/commit/a1a1fe0ca8e9ca56755b651884a2f461f9a08e0f and published to npm
in version 1.0.23
. 🎉
When importing library to project, doing correctly all steps and building app, two warnings appear :
new NativeEventEmitter()
was called with a non-null argument without the requiredaddListener
method.new NativeEventEmitter()
was called with a non-null argument without the requiredremoveListeners
method.It is logged in console and appears as warning on device screen. I'm using expo, bare workflow. I found a solution: adding to Pushy.js two lines of code :
Then no more warnings. This is an issue from 2021, of how react native changed.