You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Action silently fails when there is too much text #448
Attempting to send a large amount of text in a block results in the action silently failing.
I found that when I attempted to recreate the webhook API call in a tool like Postman, I was getting an invalid_blocks response. This appears to be because I ran over the character limit for a block (my post was over 5000 characters), as discussed on StackOverflow.
But the GitHub Action never reported any error and succeeded. I would have expected the failed API call to result in the action also failing.
Hi @mcasperson 👋🏻 Thanks for sharing this issue and for confirming the valid error with the Webhook API. That's immensely helpful 🙇🏻
❓ What version of the Slack GitHub Action are using? We've recently added some additional error handling, so I'd just like to confirm that this a bug in the latest version.
👋 Adding to what @mwbrooks has said, @v2 has an errors option to return an exit code for errors from the API that defaults to false.
This default is used to avoid blocking CI during unexpected downtime or from invalid IDs, but might require setting this value to true to raise the errors you're expecting 📚
I'm also curious about the step inputs being used though? We can look into improving how errors are surfaced in all cases! 👾 ✨
It seems we are running into this issue as well. We use this action to send our continuously growing sprint changelog to Slack and this can grow quite large. We have temporarily (?) added the errors: true option and the GitHub action now logs the following:
Error: SlackError: Request failed with status code 400
Error: Request failed with status code 400
SlackError: Request failed with status code 400
at Webhook.post (file:///home/runner/work/_actions/slackapi/slack-github-action/45a88b9581bfab2566dc881e2cd66d334e621e2c/src/webhook.js:40:1)
at processTicksAndRejections (node:internal/process/task_queues:104:5)
at post (file:///home/runner/work/_actions/slackapi/slack-github-action/45a88b9581bfab2566dc881e2cd66d334e621e2c/src/send.js:34:1)
at send (file:///home/runner/work/_actions/slackapi/slack-github-action/45a88b9581bfab2566dc881e2cd66d334e621e2c/src/send.js:14:1)
at file:///home/runner/work/_actions/slackapi/slack-github-action/45a88b9581bfab2566dc881e2cd66d334e621e2c/src/index.js:9:1
file:///home/runner/work/_actions/slackapi/slack-github-action/45a88b9581bfab2566dc881e2cd66d334e621e2c/src/webhook.js:40
throw new SlackError(config.core, response.message);
^
SlackError: Request failed with status code 400
at Webhook.post (file:///home/runner/work/_actions/slackapi/slack-github-action/45a88b9581bfab2566dc881e2cd66d334e621e2c/src/webhook.js:40:1)
at processTicksAndRejections (node:internal/process/task_queues:104:5)
at post (file:///home/runner/work/_actions/slackapi/slack-github-action/45a88b9581bfab2566dc881e2cd66d334e621e2c/src/send.js:34:1)
at send (file:///home/runner/work/_actions/slackapi/slack-github-action/45a88b9581bfab2566dc881e2cd66d334e621e2c/src/send.js:14:1)
at file:///home/runner/work/_actions/slackapi/slack-github-action/45a88b9581bfab2566dc881e2cd66d334e621e2c/src/index.js:9:1
Is there a workaround at all for sending large messages to Slack using this action or does this require a fix?
@edgarvonk Sounds like exciting times ahead! 🚀 🔮 ✨
A stable approach for uploading lots of content might prefer to upload your changelog as either a file or as a link to the contents online. I recommend sharing contents as a file if it's in markdown already:
Activity
mwbrooks commentedon May 28, 2025
Hi @mcasperson 👋🏻 Thanks for sharing this issue and for confirming the valid error with the Webhook API. That's immensely helpful 🙇🏻
❓ What version of the Slack GitHub Action are using? We've recently added some additional error handling, so I'd just like to confirm that this a bug in the latest version.
zimeg commentedon May 28, 2025
👋 Adding to what @mwbrooks has said,
@v2has anerrorsoption to return an exit code for errors from the API that defaults to false.This default is used to avoid blocking CI during unexpected downtime or from invalid IDs, but might require setting this value to true to raise the errors you're expecting 📚
I'm also curious about the step inputs being used though? We can look into improving how errors are surfaced in all cases! 👾 ✨
mcasperson commentedon May 28, 2025
I am using version 2.1.0:
mcasperson commentedon May 28, 2025
@zimeg I was not aware of the
errorsproperty, so I'll set that to true and see if that resolves the issue. Thanks for the heads up!edgarvonk commentedon May 5, 2026
It seems we are running into this issue as well. We use this action to send our continuously growing sprint changelog to Slack and this can grow quite large. We have temporarily (?) added the
errors: trueoption and the GitHub action now logs the following:Is there a workaround at all for sending large messages to Slack using this action or does this require a fix?
zimeg commentedon May 6, 2026
@edgarvonk Sounds like exciting times ahead! 🚀 🔮 ✨
A stable approach for uploading lots of content might prefer to upload your changelog as either a file or as a link to the contents online. I recommend sharing contents as a file if it's in markdown already:
🔗 https://docs.slack.dev/tools/slack-github-action/sending-data-slack-api-method/#uploading-a-file
edgarvonk commentedon May 6, 2026
Thanks @zimeg! We will look into the option of uploading a file instead of a large message.
zimeg commentedon Aug 11, 2026
🗣️ Will close this now with changes of #666 for next release!