clansty / Q2TG

QQ 与 Telegram 群相互转发的 bot
https://t.me/Q2TGbot
GNU Affero General Public License v3.0
718 stars 73 forks source link

处理 QQ 消息时遇到问题,似乎图文混排时必现 #239

Closed magisk317 closed 1 month ago

magisk317 commented 1 month ago

版本,最新rainbowcat

[2024-07-08T13:15:38.398] [ERROR] ForwardController - 0 - 处理 QQ 消息时遇到问题 PrismaClientValidationError:
Invalid `db_1.default.message.create()` invocation in
/app/build/controllers/ForwardController.js:67:40

  64 if (!tgMessage)
  65     return;
  66 // 更新数据库
→ 67 await db_1.default.message.create({
       data: {
         qqRoomId: -**********,
         qqSenderId: **********,
         time: **********,
         brief: "[图片][图片]**********",
         seq: **********,
         rand: **********,
         pktnum: 1,
         tgChatId: **********,
         instanceId: 0,
         tgMessageText: undefined,
         tgFileId: null,
         nick: "**********",
         tgSenderId: **********,
         richHeaderUsed: false,
     +   tgMsgId: Int
       }
     })

Argument `tgMsgId` is missing.
    at Tn (/app/node_modules/.pnpm/@prisma+client@5.15.1_prisma@5.15.1/node_modules/@prisma/client/runtime/library.js:115:6855)
    at In.handleRequestError (/app/node_modules/.pnpm/@prisma+client@5.15.1_prisma@5.15.1/node_modules/@prisma/client/runtime/library.js:122:6533)
    at In.handleAndLogRequestError (/app/node_modules/.pnpm/@prisma+client@5.15.1_prisma@5.15.1/node_modules/@prisma/client/runtime/library.js:122:6211)
    at In.request (/app/node_modules/.pnpm/@prisma+client@5.15.1_prisma@5.15.1/node_modules/@prisma/client/runtime/library.js:122:5919)
    at async l (/app/node_modules/.pnpm/@prisma+client@5.15.1_prisma@5.15.1/node_modules/@prisma/client/runtime/library.js:127:11167)
    at async onQqMessage (/app/build/controllers/ForwardController.js:67:13)
    at async OicqClient.onMessage (/app/build/client/OicqClient.js:108:25) {
  clientVersion: '5.15.1'
}