Comments (13)
How are you sending the notifications? If you're sending them back to back, over the same connection I suspect you're falling victim to Issue #14 - Apple is closing the socket after the first bad notification and dropping the rest. Can you try sending them over different connections, or will a few seconds wait between them and then see what you get?
from grocer.
hey @stevenharman , thanks for the quick response. I read that issue and thats why i tried to send the push notification to the only single deleted device token, so there is only push for one connection. I tried with another device iphone 4s 7.1.1 and it gives me failed attempt as it was suppose to do, but still no feedback on iphone 5 one.
for information this is how i test
pusher=Grocer.pusher(opt)
feedback=Grocer.feedback(opt)
notification=Grocer::Notification.new( device_token: token , badge: 2, alert: 'hello')
pusher.push(notification)
after that i iterate feedback and it returns nil.
from grocer.
Well, darn. I wonder if you're also being bitten by #80 - the #each
doesn't do what you'd expect it to do. Perhaps I should re-open that one and move forward with removing Enumerable
support and instead adding our own API for iterating through feedback.
Could you try #to_a
on the feedback to force it to all be read?
from grocer.
@stevenharman , i looked over that issue aswell and i tried to see the count all i needed to see was '1' instead of 0 :) so i dont think thats it aswell, and after i tried to check it with to_a i get empty array anyway.
from grocer.
To clarify, after installing and enabling push notifications on three different phones, and then uninstalling the app on each, you're seeing the following results:
- iPhone 6, iOS 8.1.1 -
✅ Feedback received - iPhone 5, iOS 7.1.1 -
⛔ Feedback not received - iPhone 4S, iOS 7.1.1 -
✅ Feedback received
It sounds like perhaps that device 2 (iPhone 5) isn't properly being unregistered with APNS and so they're not reporting it via Feedback.
What happens if you open multiple push connections, push each notification, and then open a Feedback connection and read? We'd expect to get 3 Feedback notifications, but you're getting... how many?
from grocer.
Yes exactly, for the first problem yes when i try to send in each loop it only gives one single feedback but when i send seperatly i only get 2 feedback.device_token where i should have get 3.
from grocer.
Hmmm... I have another idea. Perhaps the notification for the iPhone 5 isn't actually being accepted by APNS. That is, it could be "bad". In such a case, APNS will write an error message on the push notification connection before closing the socket. (See the docs around Figure 5-2 on how APNS handles bad notifications.) Because the notification was "bad" and never accepted by APNS, there won't be any Feedback for it.
from grocer.
@judgetr Any luck? I'm wondering if there's something I can to help, or if this issue can be closed out. Please let me know. Thanks!
from grocer.
@stevenharman i'v been struggling with other issues i couldnt give this topich the right amount of attention nor time, but i'll be investigate a bit more within this week, thank you for your concern.I think this issue should be stay open so we can communicate better.
Have a nice one
from grocer.
+1
It looks like I'm having the same issue here. I'm using an iphone 6, and I'm able to successfully receive the notifications using grocer. However when I uninstall my ios application and try sending a notification, I don't see anything returned in my feedback. Feedback returns nil, and when I call .to_a on it before doing an .each, it returns an empty array.
from grocer.
@pkuruppu Do other devices work as expected?
from grocer.
Yes - other devices do work as expected
from grocer.
Hello @pkuruppu. I'm going to close this Issue due to inactivity. Please re-open it if you are still experiencing the problem and/or have more information to add.
Thank you!
from grocer.
Related Issues (20)
- Push sent succesfully, the lockscreen wakes up but notification doesnt show up HOT 3
- connection drops silently when notification sent to sandbox device token no error, no broken pipe not a single clue HOT 2
- Found module delegate error HOT 3
- New HTTP/2 Push Notification Provider API from Apple HOT 10
- Alert field HOT 1
- OpenSSL::SSL::SSLError: SSL_connect SYSCALL returned=5 errno=0 state=SSLv3 read server session ticket A HOT 2
- Send notifications using HTTP/2 request HOT 1
- Notification arrives in iphone5, but not in ipad HOT 4
- Rspec test case for sending ios push notification with Grocer is not working HOT 2
- Not getting notifications when badge value changed HOT 6
- Errno::EPIPE: Broken pipe HOT 2
- Best practice on using grocer for large scale push notifications HOT 2
- Best practice on using grocer for large scale push notifications
- Success method undefined on notification HOT 3
- SSL_connect returned=1 errno=0 state=unknown state: tlsv1 alert internal error HOT 2
- APNS p8 certificate HOT 2
- Acceptance testing server not working? HOT 1
- Fixnum deprecated in Ruby 2.4 HOT 1
- Not sending notifications in production using with heroku HOT 2
- How to set Priority? HOT 2
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 grocer.