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

Unexpected message author. #288

Open
zengbo opened this issue Apr 8, 2023 · 2 comments
Open

Unexpected message author. #288

zengbo opened this issue Apr 8, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@zengbo
Copy link

zengbo commented Apr 8, 2023

Describe the bug


2023-04-08T03:25:55.884442914Z Error: Unexpected message author: user.
2023-04-08T03:25:55.884490315Z     at WebSocket.<anonymous> (file:///var/chatgpt-api/src/BingAIClient.js:446:36)
2023-04-08T03:25:55.884499215Z     at WebSocket.emit (node:events:525:35)
2023-04-08T03:25:55.884505315Z     at Receiver.receiverOnMessage (/var/chatgpt-api/node_modules/ws/lib/websocket.js:1184:20)
2023-04-08T03:25:55.884512315Z     at Receiver.emit (node:events:513:28)
2023-04-08T03:25:55.884518015Z     at Receiver.dataMessage (/var/chatgpt-api/node_modules/ws/lib/receiver.js:541:14)
2023-04-08T03:25:55.884523715Z     at Receiver.getData (/var/chatgpt-api/node_modules/ws/lib/receiver.js:459:17)
2023-04-08T03:25:55.884529416Z     at Receiver.startLoop (/var/chatgpt-api/node_modules/ws/lib/receiver.js:158:22)
2023-04-08T03:25:55.884535816Z     at Receiver._write (/var/chatgpt-api/node_modules/ws/lib/receiver.js:84:10)
2023-04-08T03:25:55.884541816Z     at writeOrBuffer (node:internal/streams/writable:392:12)
2023-04-08T03:25:55.884549616Z     at _write (node:internal/streams/writable:333:

To Reproduce
使用 Bing 聊天,聊了几句会出现这个问题,聊天内容如下:


User
我们来数数吧,从1开始,轮流说,如果遇到3或者3倍数就不能说数字,而要说“过”。规则了解清楚了,我们就开始
AI
你好,我是Sydney。我了解了规则,我们开始吧。1
User
2
AI
过
User
4
AI
5
User
过
AI
7
User
8
AI
Unexpected message author: user.

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Node.js version (please complete the following information):

  • OS: [Alpine]
  • Version [e.g. 18]

Package version (please complete the following information):

  • [1.34.0]

Additional context
在 Docker 运行的
我修改了一下代码,报错信息增加了 eventMessage.author

@zengbo zengbo added the bug Something isn't working label Apr 8, 2023
@qcgm1978
Copy link

qcgm1978 commented Apr 9, 2023

新建一个chat解决了这个问题

@Maddaxman
Copy link

新建一个chat解决了这个问题

甚至有些错觉是与内容相关。例如,某些提问的内容会在第一条提问时出现Unexpected message author报错。即使重新建立chat并使用相同的提问内容,仍然会直接出现这个报错。实际上,这只是一个普通的问题而已。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants