解决了吗?目前我也遇到了,很频繁
云开发使用watch监听,经常报402002异常,如何解决?我的小程序使用了watch监听函数,目前经常报错,报错概率非常高,影响了小程序用户的使用体验,麻烦给查一下一下吧 报异常时就是等待十多秒后报出异常。。。 我的APPID为:wxdaf4eb13f330c75b 异常截图: [图片] 代码片: this.messageListener = await roomModel.model.doc(roomId).watch({ onChange: handleWatch.bind(this), onError: e => { log.error(e) this.selectComponent('#errorMessage').show('服务器连接异常...', 2000, () => { router.reLaunch() }) } })
2023-05-18没有官方人员解决吗?
watch一直报402002Error: errCode: -402002 realtime listener init watch fail | errMsg: login fail Error: invalid state: ws connection not exists, can not send message history states: UNINIT-(loginStart)->INIT_LOGGING_IN-(loginFail)->INIT_LOGIN_FAIL-(loginStart)->INIT_LOGGING_IN-(loginFail)->INIT_LOGIN_FAIL-(loginStart)->INIT_LOGGING_IN-(loginFail)->INIT_LOGIN_FAIL-(close)->CLOSED at _FSMListener (WASubContext.js?t=wechat&s=1683950966850&v=2.25.3:1) at WASubContext.js?t=wechat&s=1683950966850&v=2.25.3:1 at Set.forEach (<anonymous>) at xo.transition (WASubContext.js?t=wechat&s=1683950966850&v=2.25.3:1) at Ia.<anonymous> (WASubContext.js?t=wechat&s=1683950966850&v=2.25.3:1) at Generator.throw (<anonymous>) at t (WASubContext.js?t=wechat&s=1683950966850&v=2.25.3:1) at l (WASubContext.js?t=wechat&s=1683950966850&v=2.25.3:1)
2023-05-15请问解决了吗?
watch频繁不定时出现错误:Error: errCode: -402002 ?Error: errCode: -402002 realtime listener init watch fail | errMsg: login fail Error: invalid state: ws connection not exists, can not send message history states: UNINIT-(loginStart)->INIT_LOGGING_IN-(loginFail)->INIT_LOGIN_FAIL-(loginStart)->INIT_LOGGING_IN-(loginFail)->INIT_LOGIN_FAIL-(loginStart)->INIT_LOGGING_IN-(loginFail)->INIT_LOGIN_FAIL-(close)->CLOSED at _FSMListener (VM1158 WAService.js:2) at VM1158 WAService.js:2 at Set.forEach (<anonymous>) at _l.transition (VM1158 WAService.js:2) at fc.<anonymous> (VM1158 WAService.js:2) at Generator.throw (<anonymous>) at n (VM1158 WAService.js:2) at l (VM1158 WAService.js:2) at VM1158 WAService.js:2 at n (VM1158 WAService.js:2)(env: Windows,mp,1.05.2110290; lib: 2.21.0) errMsg内容也不都是这个,各种都有。
2023-05-13