More information for CombinedPropertyErrors on shapeshift

Hello, I just rountinely cheked my errors on my production bot and noticed that a few days ago I had the following error
ERROR - Encountered error on event listener "messageUpdate" for event "messageUpdate" at path "./dist/src/listeners/client/messageUpdate.js" CombinedPropertyError (1)
ERROR - Received one or more errors
ERROR -
ERROR - input[1]
ERROR - | [CombinedPropertyError]
ERROR -
ERROR - at ArrayValidator.handle (./node_modules/@sapphire/shapeshift/src/validators/ArrayValidator.ts:95:47)
ERROR - at ArrayValidator.parse (./node_modules/@sapphire/shapeshift/src/validators/BaseValidator.ts:92:2)
ERROR - at EmbedBuilder.addFields (./node_modules/@discordjs/builders/src/messages/embed/Embed.ts:85:29)
ERROR - at logActionUnsafe (./src/lib/structures/logs/DiscordLogManager.ts:296:6)
ERROR - Encountered error on event listener "messageUpdate" for event "messageUpdate" at path "./dist/src/listeners/client/messageUpdate.js" CombinedPropertyError (1)
ERROR - Received one or more errors
ERROR -
ERROR - input[1]
ERROR - | [CombinedPropertyError]
ERROR -
ERROR - at ArrayValidator.handle (./node_modules/@sapphire/shapeshift/src/validators/ArrayValidator.ts:95:47)
ERROR - at ArrayValidator.parse (./node_modules/@sapphire/shapeshift/src/validators/BaseValidator.ts:92:2)
ERROR - at EmbedBuilder.addFields (./node_modules/@discordjs/builders/src/messages/embed/Embed.ts:85:29)
ERROR - at logActionUnsafe (./src/lib/structures/logs/DiscordLogManager.ts:296:6)
Is it expected that i don't have more information on the error ? Because if I understand correctly here the error is just telling me "there was errors", but not telling me which... Is there anything to enable in shapeshift or the logger (object depth?) or idk to have more informations in the future? Because I can't do much with such an unhelpful error btw it happened with the following code, so my guess is that the pupa thing or my contentValue exceeded the field value max length, but i'd have liked the shapeshift error to tell me that..
// EmbedBuilder...
.addFields([
{ name: fieldOptions.contextName, value: pupa(fieldOptions.contextValue, payload), inline: true },
{ name: fieldOptions.contentName, value: contentValue || "oopsie", inline: true },
])
// EmbedBuilder...
.addFields([
{ name: fieldOptions.contextName, value: pupa(fieldOptions.contextValue, payload), inline: true },
{ name: fieldOptions.contentName, value: contentValue || "oopsie", inline: true },
])
Thanks :)
2 Replies
Favna
Favna2y ago
@kairen said it's something about @discordjs/builders uses shapeshift but other than that once custom messages are done it can be more descriptive. and custom messages are stalled on writing unit tests which I can't figure out how to do well + I have a feeling the src code might not be correct
ararou!
ararou!2y ago
Try to util.inspect the error Hopefully it should display a bit more information of the error also i think if smth was done wrong like if one of the name or values aren’t a string that could kick up an error like that as it has for me before
Want results from more Discord servers?
Add your server