puppet
puppet copied to clipboard
replace `fromId` by `talkerId`, `toId` by `listenerId`
- fromId
+ talkerId
- toId
+ listenerId
- Adding compatible code to make sure both the
talkerId
and thefromId
will be available in the payloads, - Deprecate
fromId
with Puppet v2.0
Has been implemented with v1.17+
The fromId
and toId
are both deprecated from now and will be removed in v2.0
CC @wechaty/puppet @wechaty/polyglot
下载官方案例https://github.com/wechaty/getting-started.git,运行ding-dong-bot.js,控制台一直有如下错误
- [ ] uncaughtException GError [TypeError]: this.wechat4u.contacts.filter is not a function at PuppetWechat4u.contactList
- [ ] WARN Message ready() payload.talkerId not exist! See: https://github.com/wechaty/puppet/issues/187
node 版本我用了16.20.0和18.16.0,都是相同的错误。
下载官方案例https://github.com/wechaty/getting-started.git,运行ding-dong-bot.js,控制台一直有如下错误
- [ ] uncaughtException GError [TypeError]: this.wechat4u.contacts.filter is not a function at PuppetWechat4u.contactList
- [ ] WARN Message ready() payload.talkerId not exist! See: replace
fromId
bytalkerId
,toId
bylistenerId
#187node 版本我用了16.20.0和18.16.0,都是相同的错误。
这个问题解决了吗?
下载官方案例https://github.com/wechaty/getting-started.git,运行ding-dong-bot.js,控制台一直有如下错误
- [ ] uncaughtException GError [TypeError]: this.wechat4u.contacts.filter is not a function at PuppetWechat4u.contactList
- [ ] WARN Message ready() payload.talkerId not exist! See: replace
fromId
bytalkerId
,toId
bylistenerId
#187node 版本我用了16.20.0和18.16.0,都是相同的错误。
这个问题解决了吗?
根目录的package.json里,把 wechaty-puppet-wechat4u 版本号改为 ~1.13.15 然后重新npm install,npm start即可 见:https://github.com/wechaty/wechaty/issues/2491#issuecomment-1507119899
下载官方案例https://github.com/wechaty/getting-started.git,运行ding-dong-bot.js,控制台一直有如下错误
- [ ] uncaughtException GError [TypeError]: this.wechat4u.contacts.filter is not a function at PuppetWechat4u.contactList
- [ ] WARN Message ready() payload.talkerId not exist! See: replace
fromId
bytalkerId
,toId
bylistenerId
#187node 版本我用了16.20.0和18.16.0,都是相同的错误。
这个问题解决了吗?
替换 wechaty-puppet-wechat4u
到最新的版本即可解决问题。
package.json
"wechaty-puppet-wechat4u": "~1.14.14"
terminal
make install
make bot