simmsb / calamity

A library for writing discord bots in haskell
https://hackage.haskell.org/package/calamity
MIT License
109 stars 11 forks source link

Failed to decode Error in $.roles['unicode_emoji']: parsing RawEmoji failed, expected Object, but encountered String #56

Closed Miezhiko closed 1 year ago

Miezhiko commented 1 year ago

ERROR Failed to decode Error in $.roles['unicode_emoji']: parsing RawEmoji failed, expected Object, but encountered String

and I'm getting spammed in log by:

 /calamity /calamity-loop DEBUG handling an event: PresenceUpdate
 /calamity /calamity-loop DEBUG Failed handling actions for event: "Pattern match failure in 'do' block at Calamity/Client/Client.hs:632:3-15"
simmsb commented 1 year ago

There's probably something causing verified guilds to be unparseable, I'll try and find out why

Miezhiko commented 1 year ago

@simmsb it complains: "ERROR Failed to decode Error in $.roles['unicode_emoji']: parsing RawEmoji failed, expected Object, but encountered String" at first

maybe it's because of emoji-roles with custom emojis on?

Miezhiko commented 1 year ago

@simmsb also getting

shard-id=0 ERROR Failed to decode Error in $.t: parsing Calamity.Gateway.Types.DispatchType failed, expected one of the tags ["READY","RESUMED","CHANNEL_CREATE","CHANNEL_UPDATE","CHANNEL_DELETE","CHANNEL_PINS_UPDATE","GUILD_CREATE","GUILD_UPDATE","GUILD_DELETE","GUILD_BAN_ADD","GUILD_BAN_REMOVE","GUILD_EMOJIS_UPDATE","GUILD_INTEGRATIONS_UPDATE","GUILD_MEMBER_ADD","GUILD_MEMBER_REMOVE","GUILD_MEMBER_UPDATE","GUILD_MEMBERS_CHUNK","GUILD_ROLE_CREATE","GUILD_ROLE_UPDATE","GUILD_ROLE_DELETE","INVITE_CREATE","INVITE_DELETE","MESSAGE_CREATE","MESSAGE_UPDATE","MESSAGE_DELETE","MESSAGE_DELETE_BULK","MESSAGE_REACTION_ADD","MESSAGE_REACTION_REMOVE","MESSAGE_REACTION_REMOVE_ALL","PRESENCE_UPDATE","TYPING_START","USER_UPDATE","VOICE_STATE_UPDATE","VOICE_SERVER_UPDATE","WEBHOOKS_UPDATE","INTERACTION_CREATE"], but found tag "GUILD_AUDIT_LOG_ENTRY_CREATE": "{\"t\":\"GUILD_AUDIT_LOG_ENTRY_CREATE\",\"s\":398,\"op\":0,\"d\":{\"user_id\":\"_________________\",\"target_id\":\"______________\",\"id\":\"______________\",\"changes\":[{\"new_value\":[{\"name\":\"\240\159\148\180 LIVE\",\"id\":\"_________\"}],\"key\":\"$remove\"}],\"action_type\":25,\"guild_id\":\"__________\"}}

(replaced numbers with __)

Miezhiko commented 1 year ago

Reproducible on discord.gg/gentoolinux just in case!

Not adventure!

simmsb commented 1 year ago

Okay, I've published calamity 0.8.0.0 with some fixes

Miezhiko commented 1 year ago

@simmsb awesome, I'll try out tomorrow