getredash/redash · error · Exception

Connection error to: {url} {details}.

Error message

Connection error to: {url} {details}.

What it means

Raised by Tinybird._get_from_tinybird (redash/query_runner/tinybird.py:105) when the HTTP request to the Tinybird API raises a requests.RequestException (DNS failure, connection refused, TLS error, timeout). The message embeds the URL and the exception class name plus status code when a response exists — note this fires for transport-level failures; HTTP 4xx/5xx responses that do arrive raise a different exception with response.text.

Source

Thrown at redash/query_runner/tinybird.py:105

    def _get_from_tinybird(self, endpoint, params=None):
        url = f"{self.configuration.get('url', self.DEFAULT_URL)}{endpoint}"
        authorization = f"Bearer {self.configuration.get('token')}"

        try:
            response = requests.get(
                url,
                timeout=self.configuration.get("timeout", 30),
                params=params,
                headers={"Authorization": authorization},
                verify=self.configuration.get("verify", True),
            )
        except requests.RequestException as e:
            if e.response:
                details = f"({e.__class__.__name__}, Status Code: {e.response.status_code})"
            else:
                details = f"({e.__class__.__name__})"
            raise Exception(f"Connection error to: {url} {details}.")

        if response.status_code >= 400:
            raise Exception(response.text)

        return response.json()


register(Tinybird)

View on GitHub (pinned to ca79fe988d)

Solutions

  1. From the Redash host, verify connectivity: `curl -sS https://api.tinybird.com/` and check DNS/proxy env vars
  2. Configure HTTPS_PROXY/HTTP_PROXY (and NO_PROXY) for the worker if egress goes through a proxy
  3. Verify the endpoint/token region host is spelled correctly in the data source settings
  4. Retry after transient outages; inspect the embedded exception class (ConnectionError vs Timeout) to narrow the cause
Defensive patterns

Strategy: retry

Validate before calling

import socket, requests
try:
    requests.head('https://api.tinybird.com/', timeout=5)
except requests.RequestException:
    raise RuntimeError('Tinybird endpoint unreachable from this host')

Try / catch

for attempt in range(3):
    try:
        return _get_from_tinybird(url)
    except Exception as e:
        if attempt == 2 or 'Connection error' not in str(e):
            raise
        time.sleep(2 ** attempt)

Prevention

When it happens

Trigger: Running a Tinybird data source query or refreshing its schema when the Redash server cannot reach https://api.tinybird.com (or the configured region host): blocked egress, proxy misconfiguration, DNS outage, or request timeout.

Common situations: Containerized Redash without outbound internet or with an unset HTTPS_PROXY; firewall rules blocking the analytics API; transient network outage or Tinybird endpoint temporarily unreachable; custom regional endpoint typo.

Understand the failure class

Background: 'Something went wrong' / 'Request failed (500)' / 'HTTP error! status: 404' — what failed HTTP requests actually mean and how to find the real cause — this error's family across 28 libraries.

Related errors


AI-assisted analysis of getredash/redash@ca79fe988d (2026-08-28). Data as JSON: /api/errors/d2fae21dfcc9feb8. Report an issue: GitHub.