shayypy / guilded.py

Asynchronous Guilded API wrapper for Python
https://guildedpy.rtfd.io
Other
135 stars 25 forks source link

Code Block causes 500 Error #52

Closed entropylaw closed 1 year ago

entropylaw commented 1 year ago

Describe the bug Bot sends a message to channel that contains:

``` Words and stuff ```

Causes 500 Error

Expected behavior Should post a code blocked response in the channel. would like to have formatted code blocks using ```python print() ``` or which ever language.

Actual behavior

Traceback (most recent call last):
  File "C:\Users\anomic\Desktop\code\bastard-guilded\venv\lib\site-packages\guilded\client.py", line 404, in _run_event
    await coro(*args, **kwargs)
  File "c:\Users\anomic\Desktop\code\bastard-guilded\main.py", line 92, in on_message
    await message.reply(response.choices[0].message.content)
  File "C:\Users\anomic\Desktop\code\bastard-guilded\venv\lib\site-packages\guilded\message.py", line 874, in reply
    return await self.channel.send(
  File "C:\Users\anomic\Desktop\code\bastard-guilded\venv\lib\site-packages\guilded\abc.py", line 180, in send
    data = await self._state.create_channel_message(
  File "C:\Users\anomic\Desktop\code\bastard-guilded\venv\lib\site-packages\guilded\http.py", line 527, in request
    raise GuildedServerError(response, data)
guilded.errors.GuildedServerError: 500 (InternalServerError): An unexpected error occured

Environment

shayypy commented 1 year ago

This is a Guilded bug