Open hkenter opened 2 years ago
拉取puppet-xp测试可以发图片,npm install的xp和wechaty兼容性目前不太明确
It seems that you have to pull the latest code, try npm install wechaty-puppet- xp@next
, run it again and let me know the result.
Had same issue. git pull alreadu up to date.
Run npm install wechaty-puppet-xp@next
didn't solve it for me. It was working yesterday and stoped working today.
my code
const testPNG = path.resolve('./docs/images/fruits.jpg')
const fileBox = FileBox.fromFile(testPNG)
await message.say(fileBox)
@atorber, it is still an issue. any solution
Error: Wechaty Puppet Unsupported API Error. Learn More At https://github.com/wechaty/wechaty-puppet/wiki/Compatibility at Object.throwUnsupportedError (D:\Wang\workspace\wxt\node_modules\wechaty-puppet\dist\cjs\src\throw-unsupported-error.js:6:11) at PuppetXp.messageSendFile (D:\Wang\workspace\wxt\node_modules\wechaty-puppet-xp\dist\cjs\src\puppet-xp.js:571:20) at processTicksAndRejections (node:internal/process/task_queues:96:5) at async D:\Wang\workspace\wxt\node_modules\wechaty\dist\cjs\src\sayable\deliver-sayable.js:25:17 at async WechatifiedUserClass.say (D:\Wang\workspace\wxt\node_modules\wechaty\dist\cjs\src\user-modules\contact.js:300:23)
this issue is with the error
Error: Wechaty Puppet Unsupported API Error.
if you hava success run npm install wechaty-puppet-xp@next
this will never happen,Because this error point has been removed.
So I guess that although you encounter the problem of failed image sending, it is not the same reason.
Can you provide your error information?
Had the same issue. But my case is that each time I start WeChat, the bot could send 1~2 images successfully, then throws the error.
My solution: Run WeChat in Windows 7 compatible mode.
` const { FileBox } = require('file-box'); const delay = new DelayQueueExecutor(2 * 1000) const talker = bot.Contact.load(msg.payload.talkerId)
let pic_file = FileBox.fromFile(require('path').join(_dirname, '`./../../files/pic/Overview'+ talker.payload.id +'.png'))
delay.execute(() => talker.say(pic_file)) ` 报如下错 throw new Error([ ^
Error: Wechaty Puppet Unsupported API Error. Learn More At https://github.com/wechaty/wechaty-puppet/wiki/Compatibility at Object.throwUnsupportedError (D:\Wang\workspace\wxt\node_modules\wechaty-puppet\dist\cjs\src\throw-unsupported-error.js:6:11) at PuppetXp.messageSendFile (D:\Wang\workspace\wxt\node_modules\wechaty-puppet-xp\dist\cjs\src\puppet-xp.js:571:20) at processTicksAndRejections (node:internal/process/task_queues:96:5) at async D:\Wang\workspace\wxt\node_modules\wechaty\dist\cjs\src\sayable\deliver-sayable.js:25:17 at async WechatifiedUserClass.say (D:\Wang\workspace\wxt\node_modules\wechaty\dist\cjs\src\user-modules\contact.js:300:23)