且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

为什么推送通知在 testflight 上不起作用?

更新时间:2023-01-15 21:08:40

但是当我尝试将其放在 TestFlight 上供测试人员进行测试时,它没有显示推送通知,但数据已正确接收.

But when i tried to put it on TestFlight for the testers to test it, it didn't show a push notification but the data is correctly received.

这句话令人困惑.如果没有收到推送通知,正确接收到哪些数据?

That sentence is confusing. If you didn't get the push notification, what data is correctly received?

无论如何,如果我没记错的话,对于 TestFlight,您使用的是 AdHoc 配置文件,它适用于生产推送环境.因此,您需要一个生产推送证书才能推送到通过 TestFlight 安装该应用程序的设备.此外,请不要忘记开发设备令牌与生产设备令牌不同,因此请确保使用正确的令牌.

Anyway, if I recall correctly, for TestFlight you are using an AdHoc provisioning profile, which works with the production push environment. Therefore you'll need a production push certificate in order to push to devices that installed the app via TestFlight. In addition, don't forget that development device tokens are different than production device tokens, so make sure you are using the correct tokens.