ionic3 ios设置别名一直报6002错误

jpush
ios
alias
标签: #<Tag:0x00007fb846124430> #<Tag:0x00007fb8461242f0> #<Tag:0x00007fb846124138>

(没看清i) #1

在apple developer里appis的推送项设置了,证书鉴权设置了,在xcode里Push fNotifications也开启了
但是在设置别名获取key都报6002错误,另外一样的代码打包成andorid版是没有任何问题的。
看了api 说等20秒 还是一样请问这是什么问题造成的?


#2

请提供你完整的客户端 log ,是否集成还未成功就调了设置别名的 API


(没看清i) #3

现在我这个是开发环境 在点击发送的时候可以看到当前的用户数 但是推送的消息不成功。

2018-06-12 11:57:39.560216+0800 生产信息化[12411:1634524] DiskCookieStorage changing policy from 2 to 0, cookie file: file:///private/var/mobile/Containers/Data/Application/F21BDEC2-8CC4-4856-AC57-023E3EBF5BBD/Library/Cookies/Cookies.binarycookies
2018-06-12 11:57:39.735556+0800 生产信息化[12411:1634524] You've implemented -[<UIApplicationDelegate> application:didReceiveRemoteNotification:fetchCompletionHandler:], but you still need to add "remote-notification" to the list of your supported UIBackgroundModes in your Info.plist.
2018-06-12 11:57:39.744506+0800 生产信息化[12411:1634524] Apache Cordova native platform version 4.5.3 is starting.
2018-06-12 11:57:39.745770+0800 生产信息化[12411:1634524] Multi-tasking -> Device: YES, App: YES
2018-06-12 11:57:39.756428+0800 生产信息化[12411:1634524] CDVWKWebViewEngine: trying to inject XHR polyfill
2018-06-12 11:57:41.657937+0800 生产信息化[12411:1634524] CDVWKWebViewEngine will reload WKWebView if required on resume
2018-06-12 11:57:41.657998+0800 生产信息化[12411:1634524] Using Ionic WKWebView
2018-06-12 11:57:41.658331+0800 生产信息化[12411:1634524] [CDVTimer][console] 0.052929ms
2018-06-12 11:57:41.658427+0800 生产信息化[12411:1634524] [CDVTimer][handleopenurl] 0.057101ms
2018-06-12 11:57:41.659697+0800 生产信息化[12411:1634524] Unlimited access to network resources
2018-06-12 11:57:41.659744+0800 生产信息化[12411:1634524] [CDVTimer][intentandnavigationfilter] 1.299024ms
2018-06-12 11:57:41.659793+0800 生产信息化[12411:1634524] [CDVTimer][gesturehandler] 0.033975ms
2018-06-12 11:57:41.680401+0800 生产信息化[12411:1634524] [CDVTimer][splashscreen] 20.590901ms
2018-06-12 11:57:41.683069+0800 生产信息化[12411:1634524] [CDVTimer][statusbar] 2.629995ms
2018-06-12 11:57:41.683090+0800 生产信息化[12411:1634524] [CDVTimer][TotalPluginStartup] 24.852037ms
2018-06-12 11:57:41.698718+0800 生产信息化[12411:1634661]  | JIGUANG | D - [JIGUANGService] Action - JPUSH begin Setup with appkey:64555f4ed5e3395611dcb582 channel:channel name isProduction:TRUE advertisingIdentifier: 
2018-06-12 11:57:41.707549+0800 生产信息化[12411:1634661]  | JIGUANG | I - [JIGUANGService] 
--------------------------- JPush Log ----------------------------
--------------------JPush SDK Version:3.0.7--build:45----------
--------------------JCore Lib Version:1.1.6--build:29----------
-----------------AppKey:64555f4ed5e3395611dcb582----------------
----------------------------------------------------------------
2018-06-12 11:57:41.707822+0800 生产信息化[12411:1634673]  | JIGUANG | I - [JIGUANGClientController] Action - jpush setup
2018-06-12 11:57:41.707968+0800 生产信息化[12411:1634661]  | JIGUANG | I - [JIGUANGClientController] Action - setup
2018-06-12 11:57:41.709901+0800 生产信息化[12411:1634673]  | JIGUANG | D - [JIGUANGUserDefaultsController] read from old keychain data
2018-06-12 11:57:41.712612+0800 生产信息化[12411:1634673]  | JIGUANG | D - [JIGUANGUserDefaultsController] no old content, set new appKey
2018-06-12 11:57:41.730746+0800 生产信息化[12411:1634659]  | JIGUANG | D - [JIGUANGPageFlow] trySetupSession
2018-06-12 11:57:41.730939+0800 生产信息化[12411:1634673]  | JIGUANG | D - [JIGUANGPageFlow] setupSession
2018-06-12 11:57:41.731244+0800 生产信息化[12411:1634673]  | JIGUANG | D - [JIGUANGPageFlow] resetCurrentPage
2018-06-12 11:57:41.731650+0800 生产信息化[12411:1634659]  | JIGUANG | W - [JIGUANGService] 请将JPush的初始化方法,添加到[UIApplication application: didFinishLaunchingWithOptions:]方法中,否则JPush将不能准确的统计到通知的点击数量。参考文档:https://docs.jiguang.cn/jpush/client/iOS/ios_guide_new/#_6
2018-06-12 11:57:42.563198+0800 生产信息化[12411:1634524] Ionic Native: deviceready event fired after 488 ms
2018-06-12 11:57:43.742956+0800 生产信息化[12411:1634658]  | JIGUANG | W - [JIGUANGClientController] Not get deviceToken yet. Maybe: your certificate not configured APNs? or current network is not so good so APNs registration failed?  or there is no APNs register code? Please refer to JPush docs.
2018-06-12 11:57:45.742641+0800 生产信息化[12411:1634658]  | JIGUANG | W - [JIGUANGClientController] Not get deviceToken yet. Maybe: your certificate not configured APNs? or current network is not so good so APNs registration failed?  or there is no APNs register code? Please refer to JPush docs.
2018-06-12 11:57:47.741473+0800 生产信息化[12411:1634661]  | JIGUANG | W - [JIGUANGClientController] Not get deviceToken yet. Maybe: your certificate not configured APNs? or current network is not so good so APNs registration failed?  or there is no APNs register code? Please refer to JPush docs.
2018-06-12 11:57:49.742261+0800 生产信息化[12411:1634661]  | JIGUANG | W - [JIGUANGClientController] Not get deviceToken yet. Maybe: your certificate not configured APNs? or current network is not so good so APNs registration failed?  or there is no APNs register code? Please refer to JPush docs.
2018-06-12 11:57:51.741390+0800 生产信息化[12411:1634673]  | JIGUANG | W - [JIGUANGClientController] Not get deviceToken yet. Maybe: your certificate not configured APNs? or current network is not so good so APNs registration failed?  or there is no APNs register code? Please refer to JPush docs.
2018-06-12 11:57:52.798100+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGService] Action - registerDeviceToken: <9eb0d4a7 64714bcd b1f16e07 c654af7e 45249422 beafc49b e9b8f725 7112e9d9>
2018-06-12 11:57:52.799143+0800 生产信息化[12411:1634662]  | JIGUANG | D - [JIGUANGUserDefaultsController] Action - setCurrentDeviceToken - 9eb0d4a764714bcdb1f16e07c654af7e45249422beafc49be9b8f7257112e9d9
2018-06-12 11:57:52.799863+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGNetworkController] Action - trySetupSession
2018-06-12 11:57:52.800809+0800 生产信息化[12411:1634662]  | JIGUANG | D - [JIGUANGHttpSessionController] Action - setupSession
2018-06-12 11:57:52.801655+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGNetworkController] userDefaut verified: 1, curNetworkStatus: 2
2018-06-12 11:57:52.802685+0800 生产信息化[12411:1634662]  | JIGUANG | D - [JIGUANGUtilities] JCOREPostNotificationWithUserInfo name: kJPFNetworkIsConnectingNotification (null)
2018-06-12 11:57:52.803727+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGSessionController] Action - connect
2018-06-12 11:57:52.804627+0800 生产信息化[12411:1634662]  | JIGUANG | D - [JIGUANGSessionController] Action - isSisOnProtect
2018-06-12 11:57:52.805557+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGSessionController] sis is not on protect
2018-06-12 11:57:52.806375+0800 生产信息化[12411:1634662]  | JIGUANG | D - [JIGUANGSessionController] Action - reset sis cache
2018-06-12 11:57:52.807218+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGAddressController] 开始Sis解析
2018-06-12 11:57:52.808588+0800 生产信息化[12411:1634662]  | JIGUANG | D - [JIGUANGAddressController] Action - sendSisRequest
2018-06-12 11:57:52.834046+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGAddressController] get address :139.198.14.15 from host : s.jpush.cn
2018-06-12 11:57:52.835102+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGAddressController] Action - sendSisRequest:toDefaultPort
2018-06-12 11:57:52.836670+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGUdpSocket] close udp socket,info:
2018-06-12 11:57:52.845303+0800 生产信息化[12411:1634661]  | JIGUANG | D - [JIGUANGUdpSocket] send udp data
2018-06-12 11:57:52.846243+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGUdpSocket] send udp data succeed
2018-06-12 11:57:52.846990+0800 生产信息化[12411:1634661]  | JIGUANG | D - [JIGUANGUdpSocket] udp socket begin send behavior
2018-06-12 11:57:52.964249+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGAddressController] Action - parse
2018-06-12 11:57:52.979842+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGAddressController] Action - parse ips address
2018-06-12 11:57:53.009520+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGAddressController] Action - parseOptionAddress
2018-06-12 11:57:53.037216+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGUdpSocket] close udp socket,info:
2018-06-12 11:57:53.038702+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGAddressController] Action - sisReport:port
2018-06-12 11:57:53.039733+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGAddressController] receive sis result
2018-06-12 11:57:53.040425+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGSessionController] Action - connectTcp
2018-06-12 11:57:53.041037+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGSessionController] Action - connectTcpAddress:
2018-06-12 11:57:53.041652+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGSessionController] connectTcp:117.121.49.69:7006
2018-06-12 11:57:53.042248+0800 生产信息化[12411:1634658]  | JIGUANG | I - [JIGUANGSessionController] connecting with coreAddr 117.121.49.69,port 7006
2018-06-12 11:57:53.049761+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGTcpSocket] 连接主机成功
2018-06-12 11:57:53.050647+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGUtilities] JCOREPostNotificationWithUserInfo name: kJPUSHNetworkDidSetupNotification (null)
2018-06-12 11:57:53.188777+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGSessionController] Action - doSendTcpRequest
2018-06-12 11:57:53.193371+0800 生产信息化[12411:1634660]  | JIGUANG | I - [JIGUANGRegistration] 
----- register info -----
Appkey: 64555f4ed5e3395611dcb582
token:9eb0d4a764714bcdb1f16e07c654af7e45249422beafc49be9b8f7257112e9d9  
 advertisingIdentifier: 
2018-06-12 11:57:53.194440+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGRegistration] Register info - strKey:iPhone0b02080b0e04020a0c$$ $$com.uxhdb.MesOBAPP$$64555f4ed5e3395611dcb582 clientInfo:11.4$$iPhone10,2$$ $$ $$channel name$$3.0.7| | |1.1.6, deviceToken:9eb0d4a764714bcdb1f16e07c654af7e45249422beafc49be9b8f7257112e9d9, aps-Environment:1, configApsEnvironment:2 advertisingIdentifier:
2018-06-12 11:57:53.995832+0800 生产信息化[12411:1634660]  | JIGUANG | I - [JIGUANGRegistration] 
----- register result -----
uid: 17665717727
registrationID:141fe1da9ef8a0efc9a 
2018-06-12 11:57:53.997572+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGTcpSocket] Got tcp command
2018-06-12 11:57:53.999167+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGSessionController] Action - onAckOrRespReceived:
2018-06-12 11:57:54.000481+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGSessionController] Action - onRegisterRespond:
2018-06-12 11:57:54.001825+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGUtilities] JCOREPostNotificationWithUserInfo name: kJPUSHNetworkDidRegisterNotification {
    RegistrationID = 141fe1da9ef8a0efc9a;
    StatusCode = 0;
}
2018-06-12 11:57:54.036369+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGSessionController] Action - doSendTcpRequest
2018-06-12 11:57:54.049616+0800 生产信息化[12411:1634660]  | JIGUANG | I - [JIGUANGLogin] 
----- login result -----
uid:17665717727 
registrationID:141fe1da9ef8a0efc9a
2018-06-12 11:57:54.050411+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGTcpSocket] Got tcp command
2018-06-12 11:57:54.051300+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGSessionController] Action - onAckOrRespReceived:
2018-06-12 11:57:54.052170+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGSessionController] Event - onLoginRespond
2018-06-12 11:57:54.082364+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGUtilities] wifi 信息:{
    itime = 1528775874;
    "mac_address" = "70:af:6a:85:55:92";
    ssid = yxst;
}
2018-06-12 11:57:54.091460+0800 生产信息化[12411:1634673]  | JIGUANG | D - [JIGUANGUtilities] WWAN 信息:{
    generation = wifi;
    itime = 1528775874;
    "mobile_country_code" = 460;
    "mobile_network_code" = 01;
    "radio_type" = gsm;
}
2018-06-12 11:57:54.097093+0800 生产信息化[12411:1634662]  | JIGUANG | D - [JIGUANGUtilities] JCOREPostNotificationWithUserInfo name: kJPUSHNetworkDidLoginNotification (null)
2018-06-12 11:57:54.097721+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGSessionController] Action - doSendTcpRequest
2018-06-12 11:57:54.098013+0800 生产信息化[12411:1634662]  | JIGUANG | I - [JIGUANGDeviceTokenReport] try to upload device token:9eb0d4a764714bcdb1f16e07c654af7e45249422beafc49be9b8f7257112e9d9
2018-06-12 11:57:54.114993+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGTcpSocket] Got tcp command
2018-06-12 11:57:54.115234+0800 生产信息化[12411:1634662]  | JIGUANG | D - [JIGUANGSessionController] Action - onAckOrRespReceived:
2018-06-12 11:57:54.124129+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGDeviceTokenReport] upload device token success, current token is : 9eb0d4a764714bcdb1f16e07c654af7e45249422beafc49be9b8f7257112e9d9
2018-06-12 11:57:54.265585+0800 生产信息化[12411:1634660]  | JIGUANG | D - [JIGUANGReport] send report:(
        {
        date = "2018-06-12";
        itime = 1528775861;
        "session_id" = bcdd52b89b10c25f2598138dcbfe9c79;
        time = "11:57:41";
        timezone = "+8";
        type = "active_launch";
    }
) log succed
2018-06-12 11:57:54.375919+0800 生产信息化[12411:1634658]  | JIGUANG | D - [JIGUANGReport] send report:(
        {
        itime = 1528775874;
        language = "zh-Hans-CN";
        model = "iPhone10,2";
        "os_version" = "11.4";
        resolution = 1242x2208;
        timezone = "+8";
        type = "device_info";
    }
) log succed
2018-06-12 11:57:54.387313+0800 生产信息化[12411:1634673]  | JIGUANG | D - [JIGUANGReport] send report:(
        {
        data =         (
                        {
                cell =                 (
                                        {
                        generation = wifi;
                        itime = 1528775874;
                        "mobile_country_code" = 460;
                        "mobile_network_code" = 01;
                        "radio_type" = gsm;
                    }
                );
                itime = 1528775874;
                wifi =                 (
                                        {
                        itime = 1528775874;
                        "mac_address" = "70:af:6a:85:55:92";
                        ssid = yxst;
                    }
                );
            }
        );
        itime = 1528775861;
        "network_type" = "WIFI,";
        type = "loc_info";
    }
) log succed
2018-06-12 11:58:00.012694+0800 生产信息化[12411:1634524] Status bar could not find cached time string image. Rendering in-process.
2018-06-12 11:58:44.579138+0800 生产信息化[12411:1634524] ### pluginInitialize
2018-06-12 11:58:44.589966+0800 生产信息化[12411:1635417]  | JIGUANG | D - [JIGUANGService] Action - registerDeviceToken: <9eb0d4a7 64714bcd b1f16e07 c654af7e 45249422 beafc49b e9b8f725 7112e9d9>
2018-06-12 11:58:44.590334+0800 生产信息化[12411:1635250]  | JIGUANG | D - [JIGUANGClientController] the same device token, not be updated again
2018-06-12 11:58:49.757416+0800 生产信息化[12411:1635418]  | JIGUANG | D - [JIGUANGService] Action - registrationID

#4

你这个日志,只看到集成是成功的,取到了 registrationID,但并未看到别名的相关设置 log,日志里面也没有报错 6002


(没看清i) #5

这个是开发环境 在生产环境上就报错


#6

请你把 报错的 log 提供上来


(没看清i) #7

又重新试了一遍
2018-06-12 14:40:07.978956+0800 生产信息化[12781:1687678] Ionic Native: deviceready event fired after 448 ms
2018-06-12 14:40:36.596880+0800 生产信息化[12781:1687678] ### pluginInitialize
2018-06-12 14:40:36.608152+0800 生产信息化[12781:1687771] | JIGUANG | D - [JIGUANGService] Action - registerDeviceToken: <c851f39c c7e3ccee 7dff3bf6 0244ef0d 9152346a c4119951 04521228 a23e70bb>
2018-06-12 14:40:36.608439+0800 生产信息化[12781:1687957] | JIGUANG | D - [JIGUANGClientController] the same device token, not be updated again
2018-06-12 14:41:00.010922+0800 生产信息化[12781:1687678] Status bar could not find cached time string image. Rendering in-process.
2018-06-12 14:41:22.631326+0800 生产信息化[12781:1688371] | JIGUANG | D - [JIGUANGService] Action - registrationID
2018-06-12 14:41:28.934135+0800 生产信息化[12781:1688370] | JIGUANG | D - [JIGUANGSessionController] Action - doSendTcpRequest
2018-06-12 14:41:29.673364+0800 生产信息化[12781:1687933] | JIGUANG | D - [JIGUANGTcpSocket] Got tcp command
2018-06-12 14:42:00.003760+0800 生产信息化[12781:1687678] Status bar could not find cached time string image. Rendering in-process.


#8

信息过少,无法分析

个人建议你阅读本帖 常见问题 - JPush 合集(持续更新) 特别是第 八点


(没看清i) #9

现在可以获取到别名了 但是接收不到推送的消息 别名和广播的方式都收不到。
发送编号 1528787498
Message ID 2696212751
推送方式 立即推送
接受对象 广播
推送内容 这是一条测试消息。
推送平台 ios
Extras {“ios”:{“sound”:“default”,“badge”:1}}
标题(title)
副标题(subtitle)
通知声音(sound) default
应用角标(badge) 1
推送结果 已发送

发送编号 1528787530
Message ID 1111643902
推送方式 立即推送
接受对象 别名:system
推送内容 这是一条测试消息。
推送平台 ios
Extras {“ios”:{“sound”:“default”,“badge”:1}}
标题(title)
副标题(subtitle)
通知声音(sound) default
应用角标(badge) 1
推送结果 已发送

这是什么情况我的 key:1517bfd3f794ac29337

另外我的ios开发环境证书我刚刚上传切以显示注册成功 但是为什么过会儿就显示已注销了?


#10

你们的证书被 revoke 了,重新生成证书上传,我们的检测是在你有推送动作后检测的。

提供你们收不到消息的设备的 registrationID 值


(没看清i) #12

registrationID 1517bfd3f794ac29337


#13

你们推送的开发环境,开发的证书被你们revoke了,重新生成证书上传!


(没看清i) #14

我并没有revoke这个操作啊,但是我在开发环境上可以获取到registrationID也可以获取到别名 但是我在生产环境下为什么就获取不到了


#15

1、现在官网的证书去 Apple 检测的时候显示就是被 revoke 的,请你们重新生成上传到官网
官网的推送证书是影响到推送,并不影响客户端的注册

2、生成环境取不到,需要你给一下日志。

在你没拿到日志的时候,我个人建议你阅读本帖 常见问题 - JPush 合集(持续更新) 特别是第 八点,之前已经说过的,请不要忽略


(没看清i) #16

为什么我设置好后 再推送又显示我的证书已注销了?


#17

你是在Apple账号那里重新创建的证书吗?


(没看清i) #18

不是的 我原先创建好后吧证书都保存了下来然后直接上传的


#19

重新去创建证书,证书被 revoke 一定要重新创建


(没看清i) #20

好的。。。。