Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: Cannot read properties of undefined (reading 'sysmsg') #112

Closed
huan opened this issue Oct 14, 2021 · 5 comments
Closed

TypeError: Cannot read properties of undefined (reading 'sysmsg') #112

huan opened this issue Oct 14, 2021 · 5 comments

Comments

@huan
Copy link
Member

huan commented Oct 14, 2021

09:25:32 ERR Config uncaughtException: TypeError: Cannot read properties of undefined (reading 'sysmsg')
 at Object.isPatMessage (/app/node_modules/wechaty-puppet-padlocal/dist/padlocal/message-parser/helpers/message-pat.js:16:19)

Details:

2021-10-14T09:25:32.106154+00:00 app[web.1]: 09:25:32 INFO on-message dingDong()
2021-10-14T09:25:32.106168+00:00 app[web.1]: 09:25:32 VERB Puppet selfId()
2021-10-14T09:25:32.106169+00:00 app[web.1]: 09:25:32 VERB Message mentionList()
2021-10-14T09:25:32.106253+00:00 app[web.1]: 09:25:32 VERB Message mentionList()
2021-10-14T09:25:32.106317+00:00 app[web.1]: 09:25:32 VERB Puppet selfId()
2021-10-14T09:25:32.106328+00:00 app[web.1]: 09:25:32 VERB Message mentionList()
2021-10-14T09:25:32.106381+00:00 app[web.1]: 09:25:32 VERB Puppet selfId()
2021-10-14T09:25:32.106395+00:00 app[web.1]: 09:25:32 VERB Puppet selfId()
2021-10-14T09:25:32.106559+00:00 app[web.1]: 09:25:32 VERB Message mentionList()
2021-10-14T09:25:32.106687+00:00 app[web.1]: 09:25:32 VERB Message mentionList()
2021-10-14T09:25:32.106711+00:00 app[web.1]: 09:25:32 VERB Puppet selfId()
2021-10-14T09:25:32.106751+00:00 app[web.1]: 09:25:32 VERB WechatyChatopera ask(有人碰到这个问题了吗,是我少配置了吗,虽然不影响使用,但是已启动,他就要打印下这个端口为-1的异常, 夏和顺顺, Room<Apache ShenYu Contributor>)
2021-10-14T09:25:32.106790+00:00 app[web.1]: 09:25:32 VERB Room topic()
2021-10-14T09:25:32.113069+00:00 app[web.1]: 09:25:32 ERR Config ###########################
2021-10-14T09:25:32.113239+00:00 app[web.1]: 09:25:32 ERR Config uncaughtException: TypeError: Cannot read properties of undefined (reading 'sysmsg')
2021-10-14T09:25:32.113240+00:00 app[web.1]: at Object.isPatMessage (/app/node_modules/wechaty-puppet-padlocal/dist/padlocal/message-parser/helpers/message-pat.js:16:19)
2021-10-14T09:25:32.113241+00:00 app[web.1]: at processTicksAndRejections (node:internal/process/task_queues:96:5)
2021-10-14T09:25:32.113241+00:00 app[web.1]: at async Object.padLocalMessageToWechaty (/app/node_modules/wechaty-puppet-padlocal/dist/padlocal/schema-mapper/index.js:42:36)
2021-10-14T09:25:32.113241+00:00 app[web.1]: at async PuppetPadlocal.messagePayload (/app/node_modules/wechaty-puppet/dist/cjs/src/puppet.js:525:25)
2021-10-14T09:25:32.113242+00:00 app[web.1]: at async WechatifiedMessage.ready (file:///app/node_modules/wechaty/dist/esm/src/user/message.js:716:56) uncaughtException
2021-10-14T09:25:32.113259+00:00 app[web.1]: 09:25:32 ERR Config ###########################
2021-10-14T09:25:32.113327+00:00 app[web.1]: 09:25:32 ERR Config ###########################
2021-10-14T09:25:32.113350+00:00 app[web.1]: 09:25:32 ERR Config uncaughtException: TypeError: Cannot read properties of undefined (reading 'sysmsg')
2021-10-14T09:25:32.113351+00:00 app[web.1]: at Object.isPatMessage (/app/node_modules/wechaty-puppet-padlocal/dist/padlocal/message-parser/helpers/message-pat.js:16:19)
2021-10-14T09:25:32.113351+00:00 app[web.1]: at processTicksAndRejections (node:internal/process/task_queues:96:5)
2021-10-14T09:25:32.113352+00:00 app[web.1]: at async Object.padLocalMessageToWechaty (/app/node_modules/wechaty-puppet-padlocal/dist/padlocal/schema-mapper/index.js:42:36)
2021-10-14T09:25:32.113352+00:00 app[web.1]: at async PuppetPadlocal.messagePayload (/app/node_modules/wechaty-puppet/dist/cjs/src/puppet.js:525:25)
2021-10-14T09:25:32.113352+00:00 app[web.1]: at async WechatifiedMessage.ready (file:///app/node_modules/wechaty/dist/esm/src/user/message.js:716:56) uncaughtException
2021-10-14T09:25:32.113362+00:00 app[web.1]: 09:25:32 ERR Config ###########################
2021-10-14T09:25:32.113468+00:00 app[web.1]: finis Caught exception: TypeError: Cannot read properties of undefined (reading 'sysmsg')
2021-10-14T09:25:32.113468+00:00 app[web.1]: at Object.isPatMessage (/app/node_modules/wechaty-puppet-padlocal/dist/padlocal/message-parser/helpers/message-pat.js:16:19)
2021-10-14T09:25:32.113469+00:00 app[web.1]: at processTicksAndRejections (node:internal/process/task_queues:96:5)
2021-10-14T09:25:32.113469+00:00 app[web.1]: at async Object.padLocalMessageToWechaty (/app/node_modules/wechaty-puppet-padlocal/dist/padlocal/schema-mapper/index.js:42:36)
2021-10-14T09:25:32.113469+00:00 app[web.1]: at async PuppetPadlocal.messagePayload (/app/node_modules/wechaty-puppet/dist/cjs/src/puppet.js:525:25)
2021-10-14T09:25:32.113470+00:00 app[web.1]: at async WechatifiedMessage.ready (file:///app/node_modules/wechaty/dist/esm/src/user/message.js:716:56) Exception origin: uncaughtException
2021-10-14T09:25:32.113615+00:00 app[web.1]: 09:25:32 INFO RestartReporter finis(99, uncaughtException)
2021-10-14T09:25:32.113663+00:00 app[web.1]: 09:25:32 VERB HAWechaty logonoff()
2021-10-14T09:25:32.113719+00:00 app[web.1]: 09:25:32 INFO RestartReporter finis() announce exiting
2021-10-14T09:25:32.113783+00:00 app[web.1]: 09:25:32 INFO Chatops roomMessage(18995691396@chatroom, Der! I'm going to exit now, see you, bye!
2021-10-14T09:25:32.113784+00:00 app[web.1]: OSSChat v0.10.41)
2021-10-14T09:25:32.113794+00:00 app[web.1]: 09:25:32 VERB HAWechaty logonoff()
2021-10-14T09:25:32.113815+00:00 app[web.1]: 09:25:32 VERB HAWechaty roomLoad(18995691396@chatroom)
2021-10-14T09:25:32.113869+00:00 app[web.1]: 09:25:32 VERB Room ready()
2021-10-14T09:25:32.113914+00:00 app[web.1]: TypeError: Cannot read properties of undefined (reading 'sysmsg')
2021-10-14T09:25:32.113915+00:00 app[web.1]: at Object.isPatMessage (/app/node_modules/wechaty-puppet-padlocal/dist/padlocal/message-parser/helpers/message-pat.js:16:19)
2021-10-14T09:25:32.113915+00:00 app[web.1]: at processTicksAndRejections (node:internal/process/task_queues:96:5)
2021-10-14T09:25:32.113915+00:00 app[web.1]: at async Object.padLocalMessageToWechaty (/app/node_modules/wechaty-puppet-padlocal/dist/padlocal/schema-mapper/index.js:42:36)
2021-10-14T09:25:32.113916+00:00 app[web.1]: at async PuppetPadlocal.messagePayload (/app/node_modules/wechaty-puppet/dist/cjs/src/puppet.js:525:25)
2021-10-14T09:25:32.113916+00:00 app[web.1]: at async WechatifiedMessage.ready (file:///app/node_modules/wechaty/dist/esm/src/user/message.js:716:56)
2021-10-14T09:25:32.114024+00:00 app[web.1]: finis: exit code: 1
2021-10-14T09:25:32.114103+00:00 app[web.1]: 09:25:32 WARN RestartReporter finis(1, exit) called again when quiting... enforce QUIT
2021-10-14T09:25:32.253387+00:00 heroku[web.1]: Process exited with status 255
2021-10-14T09:25:32.314657+00:00 heroku[web.1]: State changed from up to crashed
@paulhybryant
Copy link

Is there a workaround for this? My bot is failing frequently with this error

@suntong
Copy link

suntong commented Jan 16, 2022

My bot is failing frequently with this error too

@paulhybryant
Copy link

@suntong
FYI you can get around this issue by changing:
node_modules/wechaty-puppet-padlocal/dist/padlocal/message-parser/helpers/message-pat.js

return false when patXML is null
However, a permanent fix would be more ideal

@suntong
Copy link

suntong commented Jan 17, 2022

Oh, thanks a lot sir!

vinceyyy added a commit to vinceyyy/puppet-padlocal that referenced this issue Jan 28, 2022
padlocal added a commit that referenced this issue Apr 29, 2022
@padlocal
Copy link
Collaborator

fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants