chris
01/03/2025, 9:19 PMThe notification block was invalid: KeyError(\"No class found for dispatch key 'discord-webhook' in registry for type 'Block'.\")
is there some step I missed when setting up my automation?Marvin
01/03/2025, 9:19 PMbash
prefect block register -m prefect.blocks.notifications
This command registers all built-in notification blocks, which might resolve the issue if the Discord block wasn't registered initially. More information on block registration can be found here.
2. Discord Webhook Configuration: There seems to be an issue with the Discord block requiring a webhook ID and token, which Discord no longer provides. Instead, you should use the complete webhook URL. This discrepancy might be causing the error. There are ongoing discussions about this issue in the Prefect GitHub repository, indicating that the current setup might not align with Discord's updated API. You can read more about it here and here.
3. Prefect Version Compatibility: Make sure you are using a compatible version of Prefect that supports the latest Discord webhook configurations. The issues noted are specific to certain Prefect versions, so upgrading or aligning your setup with the documented configurations might help.
If these steps don't resolve your issue, consider following the ongoing discussions in the GitHub issues for potential updates or workarounds.