Skip to content

Migrate Exasol provider to pyexasol 2.x#69987

Closed
Rishabjain999 wants to merge 1 commit into
apache:mainfrom
Rishabjain999:fix/exasol-pyexasol-2x
Closed

Migrate Exasol provider to pyexasol 2.x#69987
Rishabjain999 wants to merge 1 commit into
apache:mainfrom
Rishabjain999:fix/exasol-pyexasol-2x

Conversation

@Rishabjain999

Copy link
Copy Markdown

pyexasol 2.x ships a py.typed marker that exposed 8 type mismatches in
the Exasol hook, causing CI to cap the dependency at <2. This PR removes
the cap by fixing the hook to be compatible with pyexasol 2.x.

Changes:

  • Rename reused conn variable in get_conn() to airflow_conn / exa_conn
    to eliminate the mypy type-narrowing conflict.
  • Add _validate_query_params() static method to narrow
    Iterable|Mapping|Nonedict|None, matching pyexasol 2.x's
    execute() and export_to_pandas() signatures. Raises TypeError
    with a clear message for non-dict input.
  • Narrow sql: str | list[str]sql: str in get_records() and
    get_first(), matching what pyexasol actually accepts.
  • Bump pyexasol dependency from >=0.26.0,<2 to >=2.0.0,<3.
  • Update existing test to use dict parameters (tuples were never valid).
  • Add negative tests for non-dict parameters and list SQL inputs.

closes: #69123

pyexasol 2.x ships a py.typed marker that exposed type mismatches in the
Exasol hook. This removes the temporary <2 version cap and fixes all 8
mypy errors:

- Rename the reused `conn` variable in get_conn() to `airflow_conn` /
  `exa_conn` to eliminate the type-narrowing conflict.
- Add _validate_query_params() to narrow Iterable|Mapping|None down to
  dict|None, matching pyexasol 2.x's execute() and export_to_pandas()
  signatures. Raises TypeError with a clear message for non-dict input.
- Narrow sql: str|list[str] to sql: str in get_records() and get_first(),
  matching what pyexasol actually accepts.
- Bump pyexasol dependency from >=0.26.0,<2 to >=2.0.0,<3.

closes: apache#69123
@boring-cyborg

boring-cyborg Bot commented Jul 16, 2026

Copy link
Copy Markdown

Congratulations on your first Pull Request and welcome to the Apache Airflow community! If you have any issues or are unsure about any anything please check our Contributors' Guide
Here are some useful points:

  • Pay attention to the quality of your code (ruff, mypy and type annotations). Our prek-hooks will help you with that.
  • In case of a new feature add useful documentation (in docstrings or in docs/ directory). Adding a new operator? Check this short guide Consider adding an example Dag that shows how users should use it.
  • Consider using Breeze environment for testing locally, it's a heavy docker but it ships with a working Airflow and a lot of integrations.
  • Be patient and persistent. It might take some time to get a review or get the final approval from Committers.
  • Please follow ASF Code of Conduct for all communication including (but not limited to) comments on Pull Requests, Mailing list and Slack.
  • Be sure to read the Airflow Coding style.
  • Always keep your Pull Requests rebased, otherwise your build might fail due to changes not related to your commits.
    Apache Airflow is a community-driven project and together we are making it better 🚀.
    In case of doubts contact the developers at:
    Mailing List: dev@airflow.apache.org
    Slack: https://s.apache.org/airflow-slack

@eladkal

eladkal commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

We already have several PRs for that issue. We don't need more. Please help review the previously submitted PRs

@eladkal eladkal closed this Jul 16, 2026
@Rishabjain999

Copy link
Copy Markdown
Author

@eladkal any other pr or issue I can work on?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Migrate exasol provider to pyexasol 2.x and remove the <2 cap

3 participants