snowby666 / poe-api-wrapper

👾 A Python API wrapper for Poe.com. With this, you will have free access to GPT-4, Claude, Llama, Gemini, Mistral and more! 🚀
https://pypi.org/project/poe-api-wrapper/
GNU General Public License v3.0
687 stars 82 forks source link

Fixes "linkifiedText" error when cancelling message #82

Closed samuelchristlie closed 7 months ago

samuelchristlie commented 7 months ago

Removing linkifiedText fixes #81. I'm not sure what it does or if it's required at all, since it's not used in any other part of the code. Performing a network analysis on Poe gives the following request JSON, which has no mention of linkifiedText:

{"queryName":"stopMessage_messageCancel_Mutation","variables":{"messageId":xxx,"textLength":xxx},"extensions":{"hash":"xxx"}}

Removing linkifiedTextLength from line 900 in api.py fixes my problem

variables = {"messageId": chunk["messageId"], "textLength": len(chunk["text"]), "linkifiedTextLength": len(chunk["linkifiedText"])}
snowby666 commented 7 months ago

Theres a syntax error with the spare ")" at the end.