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

ERR MatrixHandler onEvent() rejection: no matrix user id found) #59

Open
zhangchunsheng opened this issue Nov 18, 2020 · 2 comments
Open
Labels
question Further information is requested

Comments

@zhangchunsheng
Copy link
Member

cat config.yaml

domain: xxx.com
homeserverUrl: https://matrix.xxx.com
registration: wechaty-registration.yaml

cat wechaty-registration.yaml

id: wechaty
hs_token: xxx
as_token: xxx
url: 'http://xxx:8788'
sender_localpart: wechaty
protocols:
  - wechaty
namespaces:
  aliases:
    - exclusive: true
      regex: '#wechaty_.*'
  users:
    - exclusive: true
      regex: '@wechaty_.*'
rate_limited: false

cat docker-compose.yml

version: '2'
services:
  matrix-appservice-wechaty:
      container_name: matrix-appservice-wechaty
      image: wechaty/matrix-appservice
      volumes:
        - ./config:/data
      networks:
        - default
      environment:
        - WECHATY_PUPPET_PADPLUS_TOKEN=xxx
        - WECHATY_PUPPET=wechaty-puppet-padplus
      command: ["--config", "/data/config.yaml", "--file", "/data/wechaty-registration.yaml"]
      ports:
        - 8788:8788

!login

matrix-appservice-wechaty    | 16:06:34 ERR MatrixHandler onEvent() rejection: no matrix user id found)
matrix-appservice-wechaty    | Error: no matrix user id found)
matrix-appservice-wechaty    |     at MiddleManager.<anonymous> (/matrix-appservice-wechaty/dist/src/middle-manager.js:294:23)
matrix-appservice-wechaty    |     at Generator.next (<anonymous>)
matrix-appservice-wechaty    |     at /matrix-appservice-wechaty/dist/src/middle-manager.js:8:71
matrix-appservice-wechaty    |     at new Promise (<anonymous>)
matrix-appservice-wechaty    |     at __awaiter (/matrix-appservice-wechaty/dist/src/middle-manager.js:4:12)
matrix-appservice-wechaty    |     at MiddleManager.directMessageUserPair (/matrix-appservice-wechaty/dist/src/middle-manager.js:290:16)
matrix-appservice-wechaty    |     at MatrixHandler.<anonymous> (/matrix-appservice-wechaty/dist/src/matrix-handler.js:169:64)
matrix-appservice-wechaty    |     at Generator.next (<anonymous>)
matrix-appservice-wechaty    |     at /matrix-appservice-wechaty/dist/src/matrix-handler.js:8:71
matrix-appservice-wechaty    |     at new Promise (<anonymous>)
matrix-appservice-wechaty    |     at __awaiter (/matrix-appservice-wechaty/dist/src/matrix-handler.js:4:12)
matrix-appservice-wechaty    |     at MatrixHandler.processDirectMessage (/matrix-appservice-wechaty/dist/src/matrix-handler.js:166:16)
matrix-appservice-wechaty    |     at MatrixHandler.<anonymous> (/matrix-appservice-wechaty/dist/src/matrix-handler.js:158:28)
matrix-appservice-wechaty    |     at Generator.next (<anonymous>)
matrix-appservice-wechaty    |     at fulfilled (/matrix-appservice-wechaty/dist/src/matrix-handler.js:5:58)

image

@huan
Copy link
Member

huan commented Nov 18, 2020

It seems that your appservice system can not get the matrixId when you sending messages to the bot.

I'd like to suggest that you can delete all the saved cache db files then try again.

https://github.com/wechaty/matrix-appservice-wechaty/blob/6a069605be0bc07fd46adfef40e800bc6aff6376/src/middle-manager.ts#L438-L447

If this issue still exists, please help yourself by reading the related source code above, it might be a bug from our source code

@huan huan added the question Further information is requested label Nov 18, 2020
@zhangchunsheng
Copy link
Member Author

It seems that your appservice system can not get the matrixId when you sending messages to the bot.

I'd like to suggest that you can delete all the saved cache db files then try again.

https://github.com/wechaty/matrix-appservice-wechaty/blob/6a069605be0bc07fd46adfef40e800bc6aff6376/src/middle-manager.ts#L438-L447

If this issue still exists, please help yourself by reading the related source code above, it might be a bug from our source code

The issue still exists after I delete the store file.

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

No branches or pull requests

2 participants