Repository navigation
build(NoTicket): update dependencies for Python 3.10 - #538
Merged
Merged
Conversation
Adapt the CASE tracking workaround to the upstream block-stack splitter and cover escaped semicolons and nested CASE expressions. Upstream fix: andialbrecht/sqlparse#839
Update runtime, test, documentation, and formatting dependencies. Remove redundant marks on fixtures rejected by pytest 9 while retaining the usage-tracker test group.
lorenzhs
marked this pull request as ready for review
October 7, 2026 11:41
gm42
approved these changes
Oct 7, 2026
|
Contributor
Author
|
integration tests: https://github.com/firebolt-db/firebolt-python-sdk/actions/runs/37616119432 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Now that the SDK requires Python 3.10, update dependencies and development tools to their latest compatible releases.
Update sqlparse to 0.6.0, which includes parser denial-of-service fixes. Adapt our CASE workaround to the new upstream block-stack splitter and add regressions for escaped semicolons and nested CASE expressions. The workaround is still needed pending sqlparse PR #839.
Also update AnyIO, Trio, mypy, pyfakefs, pytest and its plugins, pre-commit, Sphinx's Python 3.10-compatible floor, and formatting/lint hooks. Remove two ineffective fixture marks that pytest 9 rejects; the usage-tracker test retains its xdist grouping. Include the formatting changes required by the new Black release.
Validation on Python 3.10:
Live database integration tests were not rerun locally.
Note
Medium Risk
Upgrading sqlparse and rewriting statement-splitting logic can change how multi-statement queries are parsed; dependency bumps (mypy 2, pytest 9) affect CI only but runtime parsing is user-facing.
Overview
Bumps runtime and dev dependencies for the Python 3.10+ baseline: sqlparse 0.6.0 (DoS fixes), AnyIO/Trio, mypy 2.x, pytest 9 and plugins, pre-commit/Sphinx floors, and refreshed pre-commit hooks (Black 26, isort 9, flake8 7.4, etc.).
setup.cfgpins the new versions; the example notebook picks up Black-driven formatting only.The main product change is adapting SQL statement splitting after the sqlparse upgrade: the old large
_change_splitlevelmonkeypatch is replaced by a thin wrapper that delegates to sqlparse’s splitter and only adds CASE tracking outsideBEGINblocks (still pending upstream PR #839). New unit tests cover CASE expressions with escaped semicolons in literals and nested CASE when splitting multi-statement SQL.Test harness cleanup drops invalid
@mark.xdist_groupon module fixtures (pytest 9); usage-tracker parametrized tests keep their xdist group. A trivial# type: ignorespacing fix inbase_cursor.py.Reviewed by Cursor Bugbot for commit 845562c. Bugbot is set up for automated code reviews on this repo. Configure here.