Skip to content

Snowflake SQL API: Add support for statement timeout #60894

Closed

Description

@HyunWooZZ

Apache Airflow Provider(s)

snowflake

Versions of Apache Airflow Providers

6.8.2

Apache Airflow version

2.10.3

Operating System

PRETTY_NAME="Debian GNU/Linux 12 (bookworm)" NAME="Debian GNU/Linux"

Deployment

Amazon (AWS) MWAA

Deployment details

No response

What happened

Currently, when binding parameters are used, the Snowflake SQL API does not allow multi-statement queries.
Since this limitation makes it harder to control execution behavior within a single request.

What you think should happen instead

adding support for a statement-level timeout at the request level would help prevent long-running or stuck statements.

How to reproduce

Current not suport statement timeout.

Anything else

No response

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Activity

  1. added
    kind:bug
    needs-triage
    on Jan 21, 2026
  2. added
    kind:feature
    provider:snowflake
    on Jan 21, 2026
  3. HyunWooZZ commented on Jan 21, 2026

    @HyunWooZZ
    ContributorAuthor

    @dilshadshaik3031

    It would be helpful to start with this page:
    https://docs.snowflake.com/en/developer-guide/sql-api/reference#label-sql-api-reference-post-statements-request-body

    Based on that spec, we need to update the data dict in SnowflakeSqlApiHook.execute_query().

    If you need any help or clarification, feel free to reach out 🙂

  4. dilshadshaik3031 commented on Jan 21, 2026

    @dilshadshaik3031
    Contributor

    Hi @HyunWooZZ Yes. I am working on this. Thank you

  5. dilshadshaik3031 commented on Jan 22, 2026

    @dilshadshaik3031
    Contributor

    Hi @HyunWooZZ,
    I’ve implemented support for statement-level timeout by adding the corresponding field to the request payload in SnowflakeSqlApiHook.execute_query() and updated the related logic to pass it through when using the SQL API. The changes are mainly in the Snowflake provider hook and its unit tests.

    I’m currently facing some local test environment issues (pytest / provider test setup), so a few tests are not running successfully yet, but the code changes for the feature itself are in place. I’m working on stabilizing the test setup and will open a PR once the test failures are resolved.

  6. potiuk commented on Mar 2, 2026

    @potiuk
    Member

    @dilshadshaik3031 We are unassigning you from this issue as part of our updated assignment policy.

    This is not meant to discourage your contribution — quite the opposite! You are still very welcome to work on this issue and submit a PR for it. Simply comment that you are working on it and open a PR when ready.

    We found that formal assignments were not working well, as they often prevented others from contributing when the assignee was not actively working on the issue.

  7. added and removed
    kind:bug
    needs-triage
    on Mar 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:providersgood first issuekind:featureprovider:snowflake

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions