Git Product home page Git Product logo

matrix-wechat's People

Contributors

duo avatar mountcomb avatar reekystive avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

matrix-wechat's Issues

Trouble with double puppeting - sent messages not appearing on bridge

I can't get messages sent from the WeChat app to show up on Matrix. I've tried both shared secret authentication as well as the login-matrix method. Other bridges (e.g. WhatsApp, iMessages) are working fine for double puppeting and posting sent messages, so I'm not sure what's difference with the WeChat bridge.

I see this in my log:

[Aug 16, 2023 02:41:26] [Puppet/wxid_k5meyls4mino12u/DEBUG] Syncing info through wxid_k5meyls4mino12u
[Aug 16, 2023 02:41:26] [Portal/wxid_k5meyls4mino12u/DEBUG] Not handling 4487028428340278489: user doesn't have double puppeting enabled

更新docker hub的镜像

目前的docker不能直接使用,需要run之后替换matrix-wechat-agent.exe和ComWeChatRobot的文件,能否更新镜像,默认包括这些文件,感谢。

dial tcp 127.0.0.1:22223: connectex: Connection refused

项目不错。感谢!

准备搭出来自己用用,不过我使用时遇到了一些问题。日志如下:

matrix_wechat_agent_1  | time="2022-09-30T01:20:30+08:00" level=info msg="No more files."
matrix_wechat_agent_1  | [I] <MMKV.cpp:156::initialize> version v1.2.7 page size:4096
matrix_wechat_agent_1  | [I] <MMKV.cpp:198::initializeMMKV> root dir: C:\users\user\Application Data\Tencent\WeChat\XPlugin\Info\
matrix-wechat          | [Sep 30, 2022 01:20:40] [User/@pidong3:***.***.**/WARN] Error connecting to Wechat: : Post "http://127.0.0.1:22223/api/?type=9": dial tcp 127.0.0.1:22223: connectex: Connection refused.
matrix-wechat          | [Sep 30, 2022 01:20:40] [User/@pidong3:***.***.**/ERROR] Failed to log in:%!(EXTRA *wechat.ErrorResponse=: Post "http://127.0.0.1:22223/api/?type=9": dial tcp 127.0.0.1:22223: connectex: Connection refused.)

附图web客户端图
image

目前使用的是基于 docker 的 matrix-wechat-agent,
希望能给一些思路。

微信QR code無法獲取

狀況是我可以在 https://app.element.io/ 內可以找到wechatbot但頭像是空的,不會正常顯示wechat大頭貼,輸入login會發生:

Failed to upload QR code: failed to POST /_matrix/media/v3/upload: M_UNKNOWN (HTTP 500): Internal server error

螢幕擷取畫面 2024-02-07 135005

以下是synapse/homeserver.yaml

# Configuration file for Synapse.
#
# This is a YAML file: see [1] for a quick introduction. Note in particular
# that *indentation is important*: all the elements of a list or dictionary
# should have the same indentation.
#
# [1] https://docs.ansible.com/ansible/latest/reference_appendices/YAMLSyntax.html
#
# For more information on how to configure Synapse, including a complete accounting of
# each option, go to docs/usage/configuration/config_documentation.md or
# https://matrix-org.github.io/synapse/latest/usage/configuration/config_documentation.html
server_name: "XXXX"
public_baseurl: "https://XXXX"
server_wellknown: true
pid_file: /data/homeserver.pid

listeners:
    - port: 8008
      tls: false
      type: http
      x_forwarded: true
      resources:
          - names: [client, federation]
            compress: false
    - port: 8448
      tls: false
      tls_certificate_path: "/data/XXXX/fullchain1.pem"
      tls_private_key_path: "/data/XXXX/privkey1.pem"
      type: http
      x_forwarded: true
      resources:
        -   names: [ client, federation ]
            compress: false


database:
  name: psycopg2
  txn_limit: 10000
  allow_unsafe_locale: true
  args:
    user: XXXX
    password: XXXX
    database: XXXX
    host: XXXX
    port: 5432
    cp_min: 5
    cp_max: 10

log_config: "/data/example.com.log.config"
media_store_path: /data/media_store
uploads_path: /data/uploads

registration_shared_secret: "<your shared srcret>"
report_stats: false
macaroon_secret_key: "<your macaroon key>"
form_secret: "<your from secret>"
signing_key_path: "/data/example.com.signing.key"
trusted_key_servers:
  - server_name: "matrix.org"
suppress_key_server_warning: true

url_preview_enabled: true
url_preview_ip_range_blacklist:
  - '127.0.0.0/8'
  - '10.0.0.0/8'
  - '172.16.0.0/12'
  - '192.168.0.0/16'
  - '100.64.0.0/10'
  - '192.0.0.0/24'
  - '169.254.0.0/16'
  - '192.88.99.0/24'
  - '198.18.0.0/15'
  - '192.0.2.0/24'
  - '198.51.100.0/24'
  - '203.0.113.0/24'
  - '224.0.0.0/4'
  - '::1/128'
  - 'fe80::/10'
  - 'fc00::/7'
  - '2001:db8::/32'
  - 'ff00::/8'
  - 'fec0::/10'

url_preview_url_blacklist:
  - scheme: 'http'
  - netloc: '^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$'

modules:
    - module: shared_secret_authenticator.SharedSecretAuthProvider
      config:
#          shared_secret: "XXXXX"
          shared_secret: "<your double puppeting key>"
          m_login_password_support_enabled: true

app_service_config_files:
    - /data/qq-registration.yaml
    - /data/wechat-registration.yaml


# vim:ft=yaml

以下是我docker內部網路狀況,可以發現內部網路連線是正常的。

[
    {
        "Name": "skaimatrix_skaimatrix_matrix-net",
        "Id": "edc8b1e239d973ca851706b696ddfa121e3a993a1a957503fa4a6baeee1f7b76",
        "Created": "2024-02-07T12:57:12.729872881+08:00",
        "Scope": "local",
        "Driver": "bridge",
        "EnableIPv6": false,
        "IPAM": {
            "Driver": "default",
            "Options": null,
            "Config": [
                {
                    "Subnet": "192.168.48.0/24"
                }
            ]
        },
        "Internal": false,
        "Attachable": true,
        "Ingress": false,
        "ConfigFrom": {
            "Network": ""
        },
        "ConfigOnly": false,
        "Containers": {
            "497f143e9599f4d52b5f3dcd83b47d7f1766f7a6b062a69e0e3d29316042a80b": {
                "Name": "skaimatrix_pgadmin_1",
                "EndpointID": "5681e62d1093dfcc4573ab48e19d498fcfe9655e67e93bc6845164d4b4b8bf84",
                "MacAddress": "02:42:c0:a8:30:04",
                "IPv4Address": "192.168.48.4/24",
                "IPv6Address": ""
            },
            "4d44701c755b69d0e7149f114ee9de5fa7faccbb43667082c533144c532c9599": {
                "Name": "matrix-wechat-agent",
                "EndpointID": "1c1a40393a659113bbcd1d487a8e11e528758f7093f0da485e7a095e8907cc89",
                "MacAddress": "02:42:c0:a8:30:07",
                "IPv4Address": "192.168.48.7/24",
                "IPv6Address": ""
            },
            "50dff2d1c5d7a00a9f8965b0fa664d2bb5eafbca4c114bdce55ffd98bfa2fe9b": {
                "Name": "matrix-wechat",
                "EndpointID": "2725205d16f89c82ff2cf3e98d15cdc028d7dafb1baba9545a8a7f22a5fe464b",
                "MacAddress": "02:42:c0:a8:30:06",
                "IPv4Address": "192.168.48.6/24",
                "IPv6Address": ""
            },
            "679c7ac377e3c94657aefbb4e9a7137017dbd58952f266712c4284dff84d0287": {
                "Name": "matrix-qq",
                "EndpointID": "0852c4894b847831fbd13a9aac0969539f5cf3066d198e39c983730bf792abce",
                "MacAddress": "02:42:c0:a8:30:05",
                "IPv4Address": "192.168.48.5/24",
                "IPv6Address": ""
            },
            "774dead06a64e6d1bc5d606e424b460874853b4dc09866599b494b96428f9681": {
                "Name": "synapse",
                "EndpointID": "7c4a8ccf41a821aa974dcaca3ccdac2207076bdfb63fe6726f08e675f992d2c3",
                "MacAddress": "02:42:c0:a8:30:14",
                "IPv4Address": "192.168.48.20/24",
                "IPv6Address": ""
            },
            "8a5094682aad6e6a24eabe2c5851f8db467b30730c96a615c4c51ebc65f8d212": {
                "Name": "postgres",
                "EndpointID": "7d70f6099083054a37fbc9c2438b84e1e3992e7256eb9afe893fc76935bc5409",
                "MacAddress": "02:42:c0:a8:30:02",
                "IPv4Address": "192.168.48.2/24",
                "IPv6Address": ""
            },
            "9cb7d873c4406a1f5fa402ce0848312e056b88adf8a46e2a12c8eb04f372218b": {
                "Name": "caddy",
                "EndpointID": "b194a9633442d6da937d63d21d919e57332c85bb81e820485c96c8863320a984",
                "MacAddress": "02:42:c0:a8:30:03",
                "IPv4Address": "192.168.48.3/24",
                "IPv6Address": ""
            }
        },
        "Options": {},
        "Labels": {
            "com.docker.compose.network": "skaimatrix_matrix-net",
            "com.docker.compose.project": "skaimatrix"
        }
    }
]

caddy/Caddyfile:

{
	email XXXXX
}

XXXXX {
	header /.well-known/matrix/* Content-Type application/json
	header /.well-known/matrix/* Access-Control-Allow-Origin *

	respond /.well-known/matrix/server `{"m.server": "XXXXX:443"}`
	respond /.well-known/matrix/client `{"m.homeserver":{"base_url":"https://XXXX"}}`

	log {
		level INFO
		output file /data/access.log {
			roll_size 512MB
			roll_local_time
			roll_keep 10
		}
	}


	reverse_proxy /_matrix/* synapse:8008
	reverse_proxy /_synapse/client/* synapse:8008
	reverse_proxy /_wechat/* matrix-wechat:20002
}

這個是matrix-wechat的log檔案:

user@gpu:~/Desktop/skai_matrix$ docker logs -t matrix-wechat
2024-02-07T04:57:15.308244868Z Ignoring incorrect config field type !!null at bridge->hs_proxy
2024-02-07T04:57:15.310773048Z 2024-02-07T12:57:15+08:00 INF Initializing bridge built_at=unknown go_version=go1.21.5 name=matrix-wechat version=0.2.3+dev.unknown
2024-02-07T04:57:15.310806994Z 2024-02-07T12:57:15+08:00 DBG Initializing database connection
2024-02-07T04:57:15.310823109Z 2024-02-07T12:57:15+08:00 DBG Initializing state store
2024-02-07T04:57:15.311377061Z 2024-02-07T12:57:15+08:00 DBG Initializing Matrix event processor
2024-02-07T04:57:15.311393531Z 2024-02-07T12:57:15+08:00 DBG Initializing Matrix event handler
2024-02-07T04:57:15.311450572Z 2024-02-07T12:57:15+08:00 DBG Bridge built with end-to-bridge encryption, but disabled in config
2024-02-07T04:57:15.311508901Z 2024-02-07T12:57:15+08:00 INF Bridge initialization complete, starting...
2024-02-07T04:57:15.311578006Z 2024-02-07T12:57:15+08:00 DBG Running database upgrades
2024-02-07T04:57:15.343075199Z 2024-02-07T12:57:15+08:00 INF Database is up to date current_version=1 db_section=main latest_known_version=1 oldest_compatible_version=1
2024-02-07T04:57:15.347109023Z 2024-02-07T12:57:15+08:00 INF Database is up to date current_version=5 db_section=matrix_state latest_known_version=5 oldest_compatible_version=5
2024-02-07T04:57:15.347123754Z 2024-02-07T12:57:15+08:00 DBG Starting application service HTTP server
2024-02-07T04:57:15.347205530Z 2024-02-07T12:57:15+08:00 DBG Checking connection to homeserver
2024-02-07T04:57:15.347435292Z 2024-02-07T12:57:15+08:00 INF Starting HTTP listener address=0.0.0.0:17778
2024-02-07T04:57:15.349551290Z 2024-02-07T12:57:15+08:00 WRN Request failed, retrying error="Get \"http://synapse:8008/_matrix/client/versions?user_id=%40wechatbot%3Askaiqwenapi.skaispace.com\": dial tcp 192.168.48.20:8008: connect: connection refused" as_user_id=@wechatbot:skaiqwenapi.skaispace.com req_id=1 retry_in_seconds=4
2024-02-07T04:57:19.353845458Z 2024-02-07T12:57:19+08:00 DBG Request completed as_user_id=@wechatbot:skaiqwenapi.skaispace.com duration=3.784955 method=GET req_id=1 response_length=932 response_mime=application/json status_code=200 url=http://synapse:8008/_matrix/client/versions?user_id=%40wechatbot%3Askaiqwenapi.skaispace.com
2024-02-07T04:57:19.359937664Z 2024-02-07T12:57:19+08:00 DBG Request completed as_user_id=@wechatbot:skaiqwenapi.skaispace.com duration=4.715812 method=GET req_id=2 response_length=67 response_mime=application/json status_code=200 url=http://synapse:8008/_matrix/client/v3/account/whoami?user_id=%40wechatbot%3Askaiqwenapi.skaispace.com
2024-02-07T04:57:19.375937954Z 2024-02-07T12:57:19+08:00 DBG Received ping from homeserver txn_id=mautrix-go_1707281839359779575_1
2024-02-07T04:57:19.378808520Z 2024-02-07T12:57:19+08:00 DBG Request completed as_user_id=@wechatbot:skaiqwenapi.skaispace.com duration=18.701622 method=POST req_body={"transaction_id":"mautrix-go_1707281839359779575_1"} req_id=3 response_length=18 response_mime=application/json status_code=200 url=http://synapse:8008/_matrix/client/v1/appservice/wechat/ping?user_id=%40wechatbot%3Askaiqwenapi.skaispace.com
2024-02-07T04:57:19.378838572Z 2024-02-07T12:57:19+08:00 DBG Homeserver -> bridge connection works duration_ms=15 txn_id=mautrix-go_1707281839359779575_1
2024-02-07T04:57:19.378849624Z 2024-02-07T12:57:19+08:00 DBG Starting event processor
2024-02-07T04:57:19.378857693Z 2024-02-07T12:57:19+08:00 INF Bridge started!
2024-02-07T04:57:19.378871595Z 2024-02-07T12:57:19+08:00 DBG Updating bot profile
2024-02-07T04:57:19.378998724Z 2024-02-07T12:57:19+08:00 DBG Starting custom puppets
2024-02-07T04:57:19.379009144Z 2024-02-07T12:57:19+08:00 INF WechatService starting to listen on 0.0.0.0:20002 service=WeChat
2024-02-07T04:57:19.381771220Z 2024-02-07T12:57:19+08:00 DBG Request completed as_user_id=@wechatbot:skaiqwenapi.skaispace.com duration=2.717139 method=GET req_id=4 response_length=26 response_mime=application/json status_code=200 url=http://synapse:8008/_matrix/media/v3/config?user_id=%40wechatbot%3Askaiqwenapi.skaispace.com
2024-02-07T04:57:19.388530761Z 2024-02-07T12:57:19+08:00 DBG Request completed as_user_id=@wechatbot:skaiqwenapi.skaispace.com duration=8.77669 method=GET req_id=5 response_length=58 response_mime=application/json status_code=200 url=http://synapse:8008/_matrix/client/v3/profile/@wechatbot:skaiqwenapi.skaispace.com/avatar_url?user_id=%40wechatbot%3Askaiqwenapi.skaispace.com
2024-02-07T04:57:19.392326409Z 2024-02-07T12:57:19+08:00 DBG Request completed as_user_id=@wechatbot:skaiqwenapi.skaispace.com duration=3.109287 method=GET req_id=6 response_length=35 response_mime=application/json status_code=200 url=http://synapse:8008/_matrix/client/v3/profile/@wechatbot:skaiqwenapi.skaispace.com/displayname?user_id=%40wechatbot%3Askaiqwenapi.skaispace.com
2024-02-07T04:57:26.144310300Z 2024-02-07T12:57:26+08:00 INF Agent connected from 192.168.48.7:33653 service=WeChat
2024-02-07T04:57:39.228633491Z 2024-02-07T12:57:39+08:00 DBG Starting handling of transaction content={"pdu":0,"unstable_edu":1,"unstable_to_device":0} transaction_id=155
2024-02-07T04:57:39.228670277Z 2024-02-07T12:57:39+08:00 DBG Finished dispatching events from transaction transaction_id=155
2024-02-07T04:57:51.208242587Z 2024-02-07T12:57:51+08:00 DBG Starting handling of transaction content={"pdu":0,"unstable_edu":1,"unstable_to_device":0} transaction_id=156
2024-02-07T04:57:51.208289342Z 2024-02-07T12:57:51+08:00 DBG Finished dispatching events from transaction transaction_id=156
2024-02-07T04:57:53.972943883Z 2024-02-07T12:57:53+08:00 DBG Starting handling of transaction content={"pdu":0,"unstable_edu":1,"unstable_to_device":0} transaction_id=157
2024-02-07T04:57:53.973014221Z 2024-02-07T12:57:53+08:00 DBG Finished dispatching events from transaction transaction_id=157
2024-02-07T04:57:54.108931434Z 2024-02-07T12:57:54+08:00 DBG Starting handling of transaction content={"pdu":1,"unstable_edu":0,"unstable_to_device":0} transaction_id=158
2024-02-07T04:57:54.109560473Z 2024-02-07T12:57:54+08:00 DBG Finished dispatching events from transaction transaction_id=158
2024-02-07T04:57:54.110002528Z 2024-02-07T12:57:54+08:00 DBG Sent message checkpoint message_checkpoint={"event_id":"$6eblY8CVHAVQlp4EqVC8abI_V3E6AZoRLf5zGvxKamg","event_type":"m.room.message","message_type":"m.text","reported_by":"BRIDGE","retry_num":0,"room_id":"!cQRAkffLbnqGJQnEAA:skaiqwenapi.skaispace.com","status":"SUCCESS","step":"BRIDGE","timestamp":1707281874109}
2024-02-07T04:57:54.111090029Z 2024-02-07T12:57:54+08:00 INF Checker for @crmado:skaiqwenapi.skaispace.com started, interval: 1m0s
2024-02-07T04:57:54.111186429Z 2024-02-07T12:57:54+08:00 DBG Send request message #1 is_login service=WeChat
2024-02-07T04:57:54.111202526Z 2024-02-07T12:57:54+08:00 DBG Sent message checkpoint message_checkpoint={"event_id":"$6eblY8CVHAVQlp4EqVC8abI_V3E6AZoRLf5zGvxKamg","event_type":"m.room.message","message_type":"m.text","reported_by":"BRIDGE","retry_num":0,"room_id":"!cQRAkffLbnqGJQnEAA:skaiqwenapi.skaispace.com","status":"SUCCESS","step":"COMMAND","timestamp":1707281874110}
2024-02-07T04:57:54.111774069Z 2024-02-07T12:57:54+08:00 DBG Received command event_id=$6eblY8CVHAVQlp4EqVC8abI_V3E6AZoRLf5zGvxKamg mx_command=login room_id=!cQRAkffLbnqGJQnEAA:skaiqwenapi.skaispace.com user_id=@crmado:skaiqwenapi.skaispace.com
2024-02-07T04:57:54.111823547Z 2024-02-07T12:57:54+08:00 DBG Send request message #2 is_login service=WeChat
2024-02-07T04:57:54.112946976Z 2024-02-07T12:57:54+08:00 DBG Receive response message #1 is_login service=WeChat
2024-02-07T04:57:54.112999989Z 2024-02-07T12:57:54+08:00 WRN Failed to get login status: PROCESS_FAILED: client not found client=@crmado:skaiqwenapi.skaispace.com service=WeChat
2024-02-07T04:57:54.113177882Z 2024-02-07T12:57:54+08:00 DBG Receive response message #2 is_login service=WeChat
2024-02-07T04:57:54.113195580Z 2024-02-07T12:57:54+08:00 WRN Failed to get login status: PROCESS_FAILED: client not found client=@crmado:skaiqwenapi.skaispace.com service=WeChat
2024-02-07T04:57:54.113248998Z 2024-02-07T12:57:54+08:00 DBG Send request message #3 is_login service=WeChat
2024-02-07T04:57:54.113952479Z 2024-02-07T12:57:54+08:00 DBG Receive response message #3 is_login service=WeChat
2024-02-07T04:57:54.113962639Z 2024-02-07T12:57:54+08:00 WRN Failed to get login status: PROCESS_FAILED: client not found client=@crmado:skaiqwenapi.skaispace.com service=WeChat
2024-02-07T04:57:54.114041116Z 2024-02-07T12:57:54+08:00 DBG Send request message #4 connect service=WeChat
2024-02-07T04:57:56.481146231Z 2024-02-07T12:57:56+08:00 DBG Receive response message #4 connect service=WeChat
2024-02-07T04:57:56.481226400Z 2024-02-07T12:57:56+08:00 DBG Send request message #5 login_qr service=WeChat
2024-02-07T04:57:59.705154985Z 2024-02-07T12:57:59+08:00 DBG Receive response message #5 login_qr service=WeChat
2024-02-07T04:57:59.712339203Z 2024-02-07T12:57:59+08:00 DBG Request completed as_user_id=@wechatbot:skaiqwenapi.skaispace.com duration=6.892559 method=POST req_body="<3652 bytes>" req_id=7 response_length=55 response_mime=application/json status_code=500 url=http://synapse:8008/_matrix/media/v3/upload?user_id=%40wechatbot%3Askaiqwenapi.skaispace.com
2024-02-07T04:57:59.712397669Z 2024-02-07T12:57:59+08:00 ERR Failed to upload QR code: failed to POST /_matrix/media/v3/upload: M_UNKNOWN (HTTP 500): Internal server error user_id=@crmado:skaiqwenapi.skaispace.com
2024-02-07T04:57:59.793515590Z 2024-02-07T12:57:59+08:00 DBG Request completed as_user_id=@wechatbot:skaiqwenapi.skaispace.com duration=79.047175 method=PUT req_body={"body":"Failed to upload QR code: failed to POST /_matrix/media/v3/upload: M_UNKNOWN (HTTP
 500): Internal server error","msgtype":"m.notice"} req_id=8 response_length=59 response_mime=application/json status_code=200 url=http://synapse:8008/_matrix/client/v3/rooms/%21cQRAkffLbnqGJQnEAA:skaiqwenapi.skaispace.com/send/m.room.message/mautrix-go_1707281879714004578_2?user_id=%40wechatbot%3Askaiqwenapi.skaispace.com
2024-02-07T04:57:59.808478230Z 2024-02-07T12:57:59+08:00 DBG Starting handling of transaction content={"pdu":1,"unstable_edu":0,"unstable_to_device":0} transaction_id=159
2024-02-07T04:57:59.808553219Z 2024-02-07T12:57:59+08:00 DBG Finished dispatching events from transaction transaction_id=159
2024-02-07T04:57:59.808858854Z 2024-02-07T12:57:59+08:00 DBG Sent message checkpoint message_checkpoint={"event_id":"$fJB3tNuE06u1p_OODTc2ufx_rLs2HX5M57MSaQMRZqg","event_type":"m.room.message","message_type":"m.notice","reported_by":"BRIDGE","retry_num":0,"room_id":"!cQRAkffLbnqGJQnEAA:skaiqwenapi.skaispace.com","status":"SUCCESS","step":"BRIDGE","timestamp":1707281879808}
2024-02-07T04:57:59.839745713Z 2024-02-07T12:57:59+08:00 DBG Starting handling of transaction content={"pdu":0,"unstable_edu":1,"unstable_to_device":0} transaction_id=160
2024-02-07T04:57:59.839782589Z 2024-02-07T12:57:59+08:00 DBG Finished dispatching events from transaction transaction_id=160
2024-02-07T04:58:03.663604001Z 2024-02-07T12:58:03+08:00 DBG Starting handling of transaction content={"pdu":0,"unstable_edu":1,"unstable_to_device":0} transaction_id=161
2024-02-07T04:58:03.663648380Z 2024-02-07T12:58:03+08:00 DBG Finished dispatching events from transaction transaction_id=161
2024-02-07T04:58:54.118118226Z 2024-02-07T12:58:54+08:00 DBG Send request message #6 is_login service=WeChat
2024-02-07T04:58:54.119935275Z 2024-02-07T12:58:54+08:00 DBG Receive response message #6 is_login service=WeChat
2024-02-07T04:59:54.118321641Z 2024-02-07T12:59:54+08:00 DBG Send request message #7 is_login service=WeChat
2024-02-07T04:59:54.120018545Z 2024-02-07T12:59:54+08:00 DBG Receive response message #7 is_login service=WeChat
2024-02-07T05:00:54.137333826Z 2024-02-07T13:00:54+08:00 DBG Send request message #8 is_login service=WeChat
2024-02-07T05:00:54.138824960Z 2024-02-07T13:00:54+08:00 DBG Receive response message #8 is_login service=WeChat
2024-02-07T05:01:34.096439611Z 2024-02-07T13:01:34+08:00 DBG Starting handling of transaction content={"pdu":0,"unstable_edu":1,"unstable_to_device":0} transaction_id=163
2024-02-07T05:01:34.096493767Z 2024-02-07T13:01:34+08:00 DBG Finished dispatching events from transaction transaction_id=163
2024-02-07T05:01:54.129419199Z 2024-02-07T13:01:54+08:00 DBG Send request message #9 is_login service=WeChat
2024-02-07T05:01:54.131270571Z 2024-02-07T13:01:54+08:00 DBG Receive response message #9 is_login service=WeChat
2024-02-07T05:02:54.129433198Z 2024-02-07T13:02:54+08:00 DBG Send request message #10 is_login service=WeChat
2024-02-07T05:02:54.131209420Z 2024-02-07T13:02:54+08:00 DBG Receive response message #10 is_login service=WeChat
2024-02-07T05:03:54.111723653Z 2024-02-07T13:03:54+08:00 DBG Send request message #11 is_login service=WeChat
2024-02-07T05:03:54.113376258Z 2024-02-07T13:03:54+08:00 DBG Receive response message #11 is_login service=WeChat
..........

這邊是matrix-wechat-agent在容器內的log檔:

user@gpu:~/Desktop/skai_matrix$ docker logs -t matrix-wechat-agent 
2024-02-07T04:57:15.638603599Z Start agent manager...
2024-02-07T04:57:15.638688717Z Start vnc...
2024-02-07T04:57:15.641542826Z Start agent...
2024-02-07T04:57:15.697883394Z /usr/bin/xauth:  file /home/user/.Xauthority does not exist
2024-02-07T04:57:15.802826561Z
2024-02-07T04:57:15.802858619Z New Xtigervnc server 'matrix-wechat-agent:5 (user)' on port 5905 for display :5.
2024-02-07T04:57:15.802866040Z Use xtigervncviewer -SecurityTypes VncAuth,TLSVnc -passwd /home/user/.vnc/passwd matrix-wechat-agent:5 to connect to the VNC server.
2024-02-07T04:57:15.802872650Z
2024-02-07T04:57:16.141638055Z time="2024-02-07 12:57:16" level=info msg="Failed to connect, sleeping for 10s and retry, error: dial tcp 192.168.48.6:20002: connectex: Connection refused."
2024-02-07T04:57:26.144514411Z time="2024-02-07 12:57:26" level=info msg="Manager starting to listen on 127.0.0.1:22222"
2024-02-07T04:57:55.418302643Z time="2024-02-07 12:57:55" level=info msg="No more files."
2024-02-07T04:57:55.461399645Z Could not create log file: No such file or directory
2024-02-07T04:57:56.480881556Z time="2024-02-07 12:57:56" level=info msg="Set wechat version to 3.8.1.26"
2024-02-07T04:57:57.015194620Z ALSA lib confmisc.c:767:(parse_card) cannot find card '0'
2024-02-07T04:57:57.015229783Z ALSA lib conf.c:4745:(_snd_config_evaluate) function snd_func_card_driver returned error: 没有那个文件或目录
2024-02-07T04:57:57.015239143Z ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings
2024-02-07T04:57:57.015245617Z ALSA lib conf.c:4745:(_snd_config_evaluate) function snd_func_concat returned error: 没有那个文件或目录
2024-02-07T04:57:57.015253038Z ALSA lib confmisc.c:1246:(snd_func_refer) error evaluating name
2024-02-07T04:57:57.015259734Z ALSA lib conf.c:4745:(_snd_config_evaluate) function snd_func_refer returned error: 没有那个文件或目录
2024-02-07T04:57:57.015266324Z ALSA lib conf.c:5233:(snd_config_expand) Evaluate error: 没有那个文件或目录
2024-02-07T04:57:57.015272661Z ALSA lib pcm.c:2660:(snd_pcm_open_noupdate) Unknown PCM default
2024-02-07T04:57:57.015305996Z ALSA lib confmisc.c:767:(parse_card) cannot find card '0'
2024-02-07T04:57:57.015313637Z ALSA lib conf.c:4745:(_snd_config_evaluate) function snd_func_card_driver returned error: 没有那个文件或目录
2024-02-07T04:57:57.015320737Z ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings
2024-02-07T04:57:57.015327087Z ALSA lib conf.c:4745:(_snd_config_evaluate) function snd_func_concat returned error: 没有那个文件或目录
2024-02-07T04:57:57.015333597Z ALSA lib confmisc.c:1246:(snd_func_refer) error evaluating name
2024-02-07T04:57:57.015339668Z ALSA lib conf.c:4745:(_snd_config_evaluate) function snd_func_refer returned error: 没有那个文件或目录
2024-02-07T04:57:57.015345850Z ALSA lib conf.c:5233:(snd_config_expand) Evaluate error: 没有那个文件或目录
2024-02-07T04:57:57.015352018Z ALSA lib pcm.c:2660:(snd_pcm_open_noupdate) Unknown PCM default

公众号的所有放到一个房间

希望可以支持公众号的所有放到一个房间

订阅号比较多 几百个,每天都有更新,能否吧他们放到一个房间里而非单独每个联系人,容易在联系人处把其他人消息刷掉

如果放到一个房间里 这样我只需要关注所有qq/微信这一屏幕就好了,不用切换,不然一会没看消息,联系人处只能显示8个被刷没了。

至于对公众号的发消息以及接受回复可以采用 @这个人 +消息去发送 回来的消息就放到房间里

当然,如果方便可以开个配置 把配置的单独放出来(这种算特别关注)

image

English documentation for Docker setup

Hi, I'm interested in using (and helping with) this project. There doesn't appear to be good English documentation for Docker setup yet. Is there a room for discussing development of this bridge?

可以让两个matrix账号共用一个wechat账号吗

我有一个用了koishi(这是个bot框架)的matrix插件,但是是appservice的形式,没办法登录客户端去登陆wechat账号,可以让其他matrix和我登陆了wechat的matrix账号共同收发消息吗

Disable Read-Receipts from matrix-qq and matrix-wechat

1
2

如图,matrix-qq和matrix-wechat都会自动添加Read-Receipts,这样会造成:

  1. 页面混乱
  2. 有时候私聊消息,聊完之后大概几分钟以后,消息已经被读了,但是matrix-wechat或者matrix-qq又发来read-receipt,告诉你这条无用的消息,然后这条消息现在处于需要被读的状态

我没有在matrix-qq和matrix-wechat的配置中找到相关开关,synapse的官方配置文档我没有找到类似的开关,谷歌说synapse可以设置send_read_receipts: false,但经过尝试并没有起到任何作用。

希望能够取消matrix-qq和matrix-wechat端的Read-Receipts

bridge bot won't even respond to `help`

Hi, this bridge has been working great for me for almost a year now. Recently I have an issue where the bridge bot won't respond to anything, even help. I've tried restarting the containers and I see the same behavior.

Here are the full logs from the bridge and the agent after recreating the containers and sending help to the bridge bot:

logs
services-bridge-wechat-1  | Ignoring incorrect config field type !!null at bridge->hs_proxy
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [INFO] Initializing matrix-wechat 0.2.1+dev.unknown (unknown with go1.20.5)
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Initializing database connection
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Initializing state store
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Initializing Matrix event processor
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Initializing Matrix event handler
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [INFO] Bridge initialization complete, starting...
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Running database upgrades
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Database/INFO] Database currently on v1, latest: v1
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Database/StateStore/INFO] Database currently on v3, latest: v3
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Checking connection to homeserver
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/Bot/DEBUG] req #1: GET https://matrix.kylrth.com/_matrix/client/versions?user_id=%40wechatbot%3Akylrth.com
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/Bot/DEBUG] req #1 (/versions) completed in 78.178928ms with status 200 and 857 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/Bot/DEBUG] req #2: GET https://matrix.kylrth.com/_matrix/client/v3/account/whoami?user_id=%40wechatbot%3Akylrth.com
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/Bot/DEBUG] req #2 (/v3/account/whoami) completed in 2.419218ms with status 200 and 52 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Helper/DEBUG] Initializing end-to-bridge encryption...
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/Bot/DEBUG] req #3: GET https://matrix.kylrth.com/_matrix/media/v3/config?user_id=%40wechatbot%3Akylrth.com
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Database/CryptoStore/INFO] Database currently on v8, latest: v8
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Helper/DEBUG] Found existing device ID for bot in database: QAKKFSACOK
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Bot/DEBUG] req #4: GET https://matrix.kylrth.com/_matrix/client/v3/login
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/Bot/DEBUG] req #3 (/_matrix/media/v3/config) completed in 2.533132ms with status 200 and 26 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Bot/DEBUG] req #4 (/v3/login) completed in 4.045345ms with status 200 and 78 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Bot/DEBUG] req #5: POST https://matrix.kylrth.com/_matrix/client/v3/login {"type":"m.login.application_service","identifier":{"type":"m.id.user","user":"@wechatbot:kylrth.com"},"device_id":"QAKKFSACOK","initial_device_display_name":"Wechat bridge"}
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Bot/DEBUG] req #5 (/v3/login) completed in 5.663794ms with status 200 and 221 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Bot/DEBUG] Stored credentials for @wechatbot:kylrth.com/QAKKFSACOK after login
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Helper/DEBUG] Logged in as bridge bot with device ID QAKKFSACOK
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Helper/DEBUG] Making sure keys are still on server
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Bot/DEBUG] req #6: POST https://matrix.kylrth.com/_matrix/client/v3/keys/query {"device_keys":{"@wechatbot:kylrth.com":["QAKKFSACOK"]}}
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Bot/DEBUG] req #6 (/v3/keys/query) completed in 11.034535ms with status 200 and 611 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Starting application service HTTP server
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Starting event processor
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Websocket proxy not configured, not starting application service websocket
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [INFO] Bridge started!
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [WeChat/INFO] WechatService starting to listen on 0.0.0.0:20002
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Starting custom puppets
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/INFO] Listening on 0.0.0.0:17778
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Helper/DEBUG] Starting syncer for receiving to-device messages
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [DEBUG] Updating bot profile
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Bot/DEBUG] req #7: POST https://matrix.kylrth.com/_matrix/client/v3/user/@wechatbot:kylrth.com/filter {"account_data":{"not_types":["*"]},"presence":{"not_types":["*"]},"room":{"account_data":{"not_types":["*"]},"ephemeral":{"not_types":["*"]},"state":{"not_types":["*"]},"timeline":{"not_types":["*"]}}}
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Puppet/wxid_b5thn7dd9w8r22u/DEBUG] Starting custom puppet @kb:kylrth.com
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/@kb:kylrth.com/DEBUG] req #8: GET https://matrix.kylrth.com/_matrix/client/v3/account/whoami
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/Bot/DEBUG] req #9: GET https://matrix.kylrth.com/_matrix/client/v3/profile/@wechatbot:kylrth.com/avatar_url?user_id=%40wechatbot%3Akylrth.com
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Bot/DEBUG] req #7 (/v3/user/@wechatbot:kylrth.com/filter) completed in 14.550717ms with status 200 and 17 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Crypto/Bot/DEBUG] req #10: GET https://matrix.kylrth.com/_matrix/client/v3/sync?filter=0&since=s1650651_115789612_920_2618231_393334_365_307754_3101571_0_55&timeout=30000
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/@kb:kylrth.com/DEBUG] req #8 (/v3/account/whoami) completed in 16.301941ms with status 200 and 73 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Database/User/WARN] Failed to insert @kb:kylrth.com: pq: duplicate key value violates unique constraint "user_uin_key"
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [INFO] Checker for @kb:kylrth.com started, interval: 1m0s
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [WeChat/Client/@kb:kylrth.com/WARN] Failed to get login status: no agent connection avaiable
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/Bot/DEBUG] req #9 (/v3/profile/@wechatbot:kylrth.com/avatar_url) completed in 12.748506ms with status 200 and 58 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/Bot/DEBUG] req #11: GET https://matrix.kylrth.com/_matrix/client/v3/profile/@wechatbot:kylrth.com/displayname?user_id=%40wechatbot%3Akylrth.com
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [Matrix/Bot/DEBUG] req #11 (/v3/profile/@wechatbot:kylrth.com/displayname) completed in 3.477473ms with status 200 and 35 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:28] [WeChat/INFO] Agent connected from: 172.20.0.3:47607
services-wechat-agent-1   | Start agent manager...
services-wechat-agent-1   | Start vnc...
services-wechat-agent-1   | Start agent...
services-wechat-agent-1   | /usr/bin/xauth:  file /home/user/.Xauthority does not exist
services-wechat-agent-1   | 
services-wechat-agent-1   | New Xtigervnc server '812f6792c6a4:5 (user)' on port 5905 for display :5.
services-wechat-agent-1   | Use xtigervncviewer -SecurityTypes VncAuth,TLSVnc -passwd /home/user/.vnc/passwd 812f6792c6a4:5 to connect to the VNC server.
services-wechat-agent-1   | 
services-wechat-agent-1   | time="2023-12-06 21:50:28" level=info msg="Manager starting to listen on 127.0.0.1:22222"
services-bridge-wechat-1  | [Dec  6, 2023 21:50:41] [Matrix/DEBUG] Starting handling of transaction 282765 ()
services-bridge-wechat-1  | [Dec  6, 2023 21:50:45] [Matrix/DEBUG] Starting handling of transaction 282768 (1 EDUs (unstable))
services-bridge-wechat-1  | [Dec  6, 2023 21:50:45] [Matrix/DEBUG] Starting handling of transaction 282770 (1 EDUs (unstable))
services-bridge-wechat-1  | [Dec  6, 2023 21:50:45] [Matrix/DEBUG] Starting handling of transaction 282772 (1 EDUs (unstable))
services-bridge-wechat-1  | [Dec  6, 2023 21:50:45] [Matrix/DEBUG] Starting handling of transaction 282773 (1 PDUs)
services-bridge-wechat-1  | [Dec  6, 2023 21:50:45] [Matrix/DEBUG] Decrypting $LDR7h_77BreudcRNjMmkRinOVBAg9WOf72lIGjjNHY4 (4E7T5f/CAkgUf6LCVBgt09+NGVvDVulyBk1h0akik8w)
services-bridge-wechat-1  | [Dec  6, 2023 21:50:45] [Crypto/Bot/DEBUG] req #12: POST https://matrix.kylrth.com/_matrix/client/v3/keys/query {"device_keys":{"@wechatbot:kylrth.com":[]}}
services-bridge-wechat-1  | [Dec  6, 2023 21:50:45] [Crypto/Bot/DEBUG] req #12 (/v3/keys/query) completed in 6.842048ms with status 200 and 611 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:45] [Matrix/DEBUG] Successfully decrypted $LDR7h_77BreudcRNjMmkRinOVBAg9WOf72lIGjjNHY4
services-bridge-wechat-1  | [Dec  6, 2023 21:50:58] [Crypto/Bot/DEBUG] req #10 (/v3/sync) completed in 30.015143233s with status 200 and 227 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:50:58] [Crypto/Bot/DEBUG] req #13: GET https://matrix.kylrth.com/_matrix/client/v3/sync?filter=0&since=s1650655_115790510_930_2618240_393334_365_307755_3101571_0_55&timeout=30000
services-bridge-wechat-1  | [Dec  6, 2023 21:51:28] [WeChat/DEBUG] Send request message #2 is_login
services-bridge-wechat-1  | [Dec  6, 2023 21:51:28] [WeChat/DEBUG] Receive response message #2 is_login
services-bridge-wechat-1  | [Dec  6, 2023 21:51:28] [WeChat/Client/@kb:kylrth.com/WARN] Failed to get login status: PROCESS_FAILED: client not found
services-bridge-wechat-1  | [Dec  6, 2023 21:51:28] [Crypto/Bot/DEBUG] req #13 (/v3/sync) completed in 30.005961935s with status 200 and 227 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:51:28] [Crypto/Bot/DEBUG] req #14: GET https://matrix.kylrth.com/_matrix/client/v3/sync?filter=0&since=s1650655_115790539_930_2618240_393335_365_307755_3101571_0_55&timeout=30000
services-bridge-wechat-1  | [Dec  6, 2023 21:51:58] [Crypto/Bot/DEBUG] req #14 (/v3/sync) completed in 30.009742492s with status 200 and 227 bytes of application/json body
services-bridge-wechat-1  | [Dec  6, 2023 21:51:58] [Crypto/Bot/DEBUG] req #15: GET https://matrix.kylrth.com/_matrix/client/v3/sync?filter=0&since=s1650655_115790649_931_2618241_393335_365_307755_3101571_0_55&timeout=30000

I think the relevant lines are the following:

[Database/User/WARN] Failed to insert @kb:kylrth.com: pq: duplicate key value violates unique constraint "user_uin_key"
[INFO] Checker for @kb:kylrth.com started, interval: 1m0s
[WeChat/Client/@kb:kylrth.com/WARN] Failed to get login status: no agent connection avaiable
...
[WeChat/Client/@kb:kylrth.com/WARN] Failed to get login status: PROCESS_FAILED: client not found

Any ideas for how to fix?

Sync messages sent from WeChat

目前一切工作良好,但是还有一个问题:

从微信客户端(例如 iOS)发送的消息不会出现在 Matrix 的客户端中。

作者的 matrix-qq 没有这个问题,所以想问一下这种 hook 微信客户端的方式有办法获取自己发送的消息吗?

关于提及功能的问题

在wechat和qq中,新版的element似乎用的
https://homeserver.org/#/user/@_wechat_wxid_uuid:homeserver.org
而这种API好像不能在微信端识别为真正的@,而是显示为
用户名称 (https://homeserver.org/#/user/@_wechat_wxid_uuid:homeserver.org)

而如果是用旧版客户端的话,API是这种模式,可以在微信端正常at
https://homeserver.org/#/@_wechat_wxid_uuid:homeserver.org

关于撤回功能的建议

现在的撤回是在其原消息上做的一个回复(如果我没理解错的话),如果是一个很长的内容或者一次性撤回了很多内容,会导致整个面板都被撤回消息所占满,从而影响正常的消息,可以考虑删除消息本身或者以其他方式来提示比较好?

求助:log显示启动成功,但在Matrix中私聊无反应

完整log记录如下:

matrix-wechat  | [Dec  3, 2022 14:23:11] [INFO] Bridge stopped.
matrix-wechat  | [Dec  3, 2022 14:23:12] [INFO] Initializing matrix-wechat 0.0.12+dev.unknown (unknown with go1.19.1)
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Initializing database connection
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Initializing state store
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Initializing Matrix event processor
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Initializing Matrix event handler
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Bridge built with end-to-bridge encryption, but disabled in config
matrix-wechat  | [Dec  3, 2022 14:23:12] [INFO] Bridge initialization complete, starting...
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Running database upgrades
matrix-wechat  | [Dec  3, 2022 14:23:12] [Database/INFO] Database currently on v1, latest: v1
matrix-wechat  | [Dec  3, 2022 14:23:12] [Database/StateStore/INFO] Database currently on v3, latest: v3
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Checking connection to homeserver
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/Bot/DEBUG] req #1: GET http://synapse:8008/_matrix/client/versions?user_id=%40wcbot%3Aqwerzl.me
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/Bot/DEBUG] req #1 (/versions) completed in 2.960478ms with status 200 and 781 bytes of application/json body
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/Bot/DEBUG] req #2: GET http://synapse:8008/_matrix/client/v3/account/whoami?user_id=%40wechatbot%3Aqwerzl.me
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/Bot/DEBUG] req #2 (/v3/account/whoami) completed in 2.83133ms with status 200 and 47 bytes of application/json body
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Starting application service HTTP server
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Starting event processor
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/Bot/DEBUG] req #3: GET http://synapse:8008/_matrix/media/v3/config?user_id=%40wcbot%3Aqwerzl.me
matrix-wechat  | [Dec  3, 2022 14:23:12] [INFO] Bridge started!
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/INFO] Listening on 0.0.0.0:17778
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Starting custom puppets
matrix-wechat  | [Dec  3, 2022 14:23:12] [DEBUG] Updating bot profile
matrix-wechat  | [Dec  3, 2022 14:23:12] [Wechat/INFO] WechatService starting to listen on 0.0.0.0:20002
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/Bot/DEBUG] req #3 (/_matrix/media/v3/config) completed in 1.954816ms with status 200 and 26 bytes of application/json body
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/Bot/DEBUG] req #4: GET http://synapse:8008/_matrix/client/v3/profile/@wechatbot:qwerzl.me/avatar_url?user_id=%40wcbot%3Aqwerzl.me
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/Bot/DEBUG] req #4 (/v3/profile/@wechatbot:qwerzl.me/avatar_url) completed in 3.318386ms with status 200 and 58 bytes of application/json body
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/Bot/DEBUG] req #5: GET http://synapse:8008/_matrix/client/v3/profile/@wechatbot:qwerzl.me/displayname?user_id=%40wcbot%3Aqwerzl.me
matrix-wechat  | [Dec  3, 2022 14:23:12] [Matrix/Bot/DEBUG] req #5 (/v3/profile/@wechatbot:qwerzl.me/displayname) completed in 2.821281ms with status 200 and 35 bytes of application/json body
matrix-wechat  | [Dec  3, 2022 14:23:13] [Wechat/INFO] WechatService websocket connected

似乎已经启动成功,也在监听websocket,但是私聊无反应。
Screenshot 2022-12-03 at 14 29 53

是否能提供些排错思路?感谢!

语音消息的通知

如题,微信电话没有消息通知
有时候手机静音在一旁,自己在电脑前,错过一堆微信电话

Group WeChat official accounts into a single space

#11 中提到的一样,在微信中订阅了大量公众号之后每天会产生大量推送,它们会和联系人混在一起,很容易错过需要处理的消息。

如果说将公众号放到一个单独的房间中会破坏一对一的对应关系,那可不可以将它们都放到一个单独的 Space 里?

[FR] XX邀请了XX 进入了群聊 消息变为matrix的群成员动态

有些微信大群人特别多,会经常有:

Keep invited 。。。 to the group chat
"Keep" joined the group chat via the QR Code shared by "XXX".
Note: "此用户已成仙" is not friends with anyone else in this group chat.

会很烦,如果能够变成像这样的形式,就没有消息提醒,而是就是一个小点,就很好
image
image

无法发送文件

matrix-wechat-agent log

I20221013 08:46:50.117060   824 ReceiveMessage.cpp:138] msgid: 0 send begin.
I20221013 08:46:50.147078   824 ReceiveMessage.cpp:139] type: 49, sender: wxid_2
I20221013 08:46:50.160075   824 ReceiveMessage.cpp:140] content size: 1668
I20221013 08:46:50.172930   824 ReceiveMessage.cpp:157] msgid: 0 send end.
I20221013 08:46:50.176676   672 ReceiveMessage.cpp:138] msgid: 0 send begin.
I20221013 08:46:50.198630   672 ReceiveMessage.cpp:139] type: 49, sender: wxid_2
I20221013 08:46:50.211843   672 ReceiveMessage.cpp:140] content size: 1668
I20221013 08:46:50.225778   672 ReceiveMessage.cpp:157] msgid: 0 send end.

matrix-wechat log

[Oct 13, 2022 15:46:49] [Matrix/DEBUG] Starting handling of transaction 16222 (1 PDUs)
[Oct 13, 2022 15:46:49] [Portal/wxid_****kkltv***22uwxid_dlf*****22u/DEBUG] Sending event $-vrJ***tVDXZ_X6amsDGiJzJn*****hak50ZcbtEM to Wechat
[Oct 13, 2022 15:46:50] [Portal/wxid_****kkltv***22uwxid_dlf*****22u/DEBUG] Handled message FAKE::16656***8849 (message) -> $-v***DXZ_X6amsDGiJzJnh***hhak50ZcbtEM

文字、emoji、图片、视频都发送正常,只有文件没有发送。

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.