windmill-labs/windmill · error
e (Slack chat.update request error propagated via anyhow)
Error message
e (Slack chat.update request error propagated via anyhow)
What it means
`update_original_slack_message` edits the original approval/interactivity message in Slack via `POST https://slack.com/api/chat.update`. Network or transport failures on `.send()` (DNS failure, connection reset, timeout) are propagated as anyhow errors wrapping the reqwest error. Note: HTTP-level errors from Slack's API (non-2xx responses with an `error` body like `message_not_found` or `invalid_auth`) are logged, not thrown — this specific error is the request-level failure path.
Source
Thrown at backend/windmill-api/src/slack_approvals.rs:1228
let payload = serde_json::json!({
"channel": container.channel_id,
"ts": container.message_ts,
"text": message,
"blocks": final_blocks,
"mrkdwn": true // Enable markdown to support emojis
});
let client = Client::new();
let response = client
.post("https://slack.com/api/chat.update")
.bearer_auth(token) // Use the token for authentication
.header("Content-Type", "application/json")
.json(&payload)
.send()
.await
.map_err(|e| Error::from(anyhow::Error::new(e)))?;
if response.status().is_success() {
tracing::debug!("Slack message updated successfully!");
} else {
tracing::error!(
"Failed to update Slack message. Status: {}, Response: {:?}",
response.status(),
response
.text()
.await
.map_err(|e| Error::from(anyhow::Error::new(e)))?
);
}
Ok(())
}
View on GitHub (pinned to e474e8803c)
Solutions
- Verify the worker/API server has outbound HTTPS access to slack.com (curl https://slack.com/api/api.test from the host)
- Check corporate proxy/firewall rules and set HTTPS_PROXY if required
- Retry the submission — transport errors to Slack are often transient
- Confirm the failure is transport-level (this error) vs a Slack API error (logged, e.g. invalid token), and check token validity for the latter
Defensive patterns
Strategy: retry
Validate before calling
// preflight: can the server reach Slack?
const ok = await fetch("https://slack.com/api/api.test").then(r => r.ok).catch(() => false);
if (!ok) throw new Error("No outbound access to slack.com"); Try / catch
try {
await updateOriginalSlackMessage(...);
} catch (e) {
// transport-level failure: check egress/proxy, then retry with backoff
await backoff(() => updateOriginalSlackMessage(...), 3);
} Prevention
- Ensure self-hosted instances have outbound HTTPS to slack.com
- Configure HTTPS_PROXY where corporate egress requires it
- Retry transient network failures with backoff
- Distinguish transport errors (thrown) from Slack API errors (logged, e.g. invalid_auth) when debugging
When it happens
Trigger: A Slack form submission handler (`handle_submission`) tries to update the original message but the HTTPS request to Slack fails at the transport layer: no outbound network access, DNS resolution failure, TLS issues, or Slack returning a 5xx/timeout at the connection level.
Common situations: Self-hosted Windmill instances without internet egress, firewalls/proxies blocking slack.com, transient Slack outages, DNS misconfiguration in containers.
Understand the failure class
Background: ECONNREFUSED and "connection refused" / "could not connect to server" errors: what they mean and how to fix them — this error's family across 44 libraries.
Related errors
- Error executing get request from authed http client to {url}
- Error streaming get request from authed http client to {url}
- ApiError with mapped HTTP status message (e.g. "Not Found",
- Generic Error: status: ${errorStatus}; status text: ${errorS
- Couldn't fetch resource types from hub ${hubBaseUrl}: ${(awa
AI-assisted analysis of windmill-labs/windmill@e474e8803c (2026-09-03).
Data as JSON: /api/errors/e0daa7fc5e283caf.
Report an issue: GitHub.