koalasthegreat / AmoeboidBot

A Magic the Gathering card bot
1 stars 1 forks source link

rulings command breaks easily with large rules text #6

Closed koalasthegreat closed 3 years ago

koalasthegreat commented 3 years ago
Traceback (most recent call last):
  File "/home/pi/.local/lib/python3.7/site-packages/discord/ext/commands/core.py", line 85, in wrapped
    ret = await coro(*args, **kwargs)
  File "/home/pi/bots/AmoeboidBot/bot.py", line 319, in _get_rulings
    await ctx.send(embed=embed)
  File "/home/pi/.local/lib/python3.7/site-packages/discord/abc.py", line 905, in send
    nonce=nonce, allowed_mentions=allowed_mentions)
  File "/home/pi/.local/lib/python3.7/site-packages/discord/http.py", line 245, in request
    raise HTTPException(r, data)
discord.errors.HTTPException: 400 Bad Request (error code: 50035): Invalid Form Body
In embed.fields.0.value: Must be 1024 or fewer in length.

Need to find a better way to implement these rulings. Maybe in the description instead, truncating the output and linking to the gatherer site for rulings

koalasthegreat commented 3 years ago

Issue should be resolved with 797535e4d4a307198f1fab2559f59f7ccc5a5959