parse-community / parse-community/parse-server-push-adapter
APNS VError: apn write failed: Not receiving Ping response after 150000 ms
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 96
- Forks
- 108
- PR merge metrics
- No merged PRs in 30d
Description
I run parse server 2.5.3 with push adapter 2.0.0.
After a lot of errors in the console APNS error transmitting to device XXXXXXXXXXXXXX with status 400 and reason BadDeviceToken I see APNS connection failing.
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS VError: apn write failed: Not receiving Ping response after 150000 ms
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS at Stream.stream.on.err (/app/node_modules/apn/lib/client.js:105:21)
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS at emitOne (events.js:115:13)
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS at Stream.emit (events.js:210:7)
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS at _connection._streamIds.forEach (/app/node_modules/apn/lib/protocol/endpoint.js:155:16)
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS at Array.forEach (native)
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS at Endpoint.close [as _close] (/app/node_modules/apn/lib/protocol/endpoint.js:139:33)
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS at emitOne (events.js:120:20)
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS at TLSSocket.emit (events.js:210:7)
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS at _handle.close (net.js:549:12)
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS at TCP.done [as _onclose] (_tls_wrap.js:350:7)
Jul 20 11:03:31 parse-server app/web.1: node-pre-gyp ERR! parse-server-push-adapter APNS APNS error transmitting to device %s with error %s
This causes push notifications to not be delivered.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the APNS failure with Parse Server 2.5.3 and push adapter 2.0.0, then inspect the logged paths in node_modules/apn/lib/client.js and node_modules/apn/lib/protocol/endpoint.js. Compare the BadDeviceToken errors with the missing Ping response; done means push notifications no longer fail with this connection timeout.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100