Skip to content

Commit

Permalink
fix!: Drop support for SQLAlchemy 1.4 (#1916)
Browse files Browse the repository at this point in the history
  • Loading branch information
edgarrmondragon committed Aug 30, 2023
1 parent 272d1d7 commit c1fcdb6
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 23 deletions.
10 changes: 3 additions & 7 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ env:

jobs:
tests:
name: "Test on ${{ matrix.python-version }} (${{ matrix.session }}) / ${{ matrix.os }} / SQLAlchemy: ${{ matrix.sqlalchemy }}"
name: "Test on ${{ matrix.python-version }} (${{ matrix.session }}) / ${{ matrix.os }}"
runs-on: ${{ matrix.os }}
env:
NOXSESSION: ${{ matrix.session }}
Expand All @@ -47,11 +47,9 @@ jobs:
session: [tests]
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
python-version: ["3.8", "3.9", "3.10", "3.11"]
sqlalchemy: ["2.*"]
include:
- { session: tests, python-version: "3.11", os: "ubuntu-latest", sqlalchemy: "1.*" }
- { session: doctest, python-version: "3.10", os: "ubuntu-latest", sqlalchemy: "2.*" }
- { session: mypy, python-version: "3.8", os: "ubuntu-latest", sqlalchemy: "2.*" }
- { session: doctest, python-version: "3.10", os: "ubuntu-latest" }
- { session: mypy, python-version: "3.8", os: "ubuntu-latest" }

steps:
- name: Check out the repository
Expand Down Expand Up @@ -88,8 +86,6 @@ jobs:
nox --version
- name: Run Nox
env:
SQLALCHEMY_VERSION: ${{ matrix.sqlalchemy }}
run: |
nox --python=${{ matrix.python-version }}
Expand Down
8 changes: 0 additions & 8 deletions noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,14 +86,6 @@ def tests(session: Session) -> None:
session.install(".[s3]")
session.install(*test_dependencies)

sqlalchemy_version = os.environ.get("SQLALCHEMY_VERSION")
if sqlalchemy_version:
# Bypass nox-poetry use of --constraint so we can install a version of
# SQLAlchemy that doesn't match what's in poetry.lock.
session.poetry.session.install( # type: ignore[attr-defined]
f"sqlalchemy=={sqlalchemy_version}",
)

try:
session.run(
"coverage",
Expand Down
2 changes: 1 addition & 1 deletion poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ memoization = ">=0.3.2,<0.5.0"
jsonpath-ng = "^1.5.3"
joblib = "^1.0.1"
inflection = "^0.5.1"
sqlalchemy = ">=1.4,<3.0"
sqlalchemy = ">=2.0,<3.0"
python-dotenv = ">=0.20,<0.22"
typing-extensions = "^4.2.0"
simplejson = "^3.17.6"
Expand Down
6 changes: 0 additions & 6 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import typing as t

import pytest
from sqlalchemy import __version__ as sqlalchemy_version

from singer_sdk import SQLConnector
from singer_sdk import typing as th
Expand Down Expand Up @@ -45,11 +44,6 @@ def pytest_runtest_setup(item):
pytest.skip(f"cannot run on platform {system}")


def pytest_report_header() -> list[str]:
"""Return a list of strings to be displayed in the header of the report."""
return [f"sqlalchemy: {sqlalchemy_version}"]


@pytest.fixture(scope="class")
def outdir() -> t.Generator[str, None, None]:
"""Create a temporary directory for cookiecutters and target output."""
Expand Down

0 comments on commit c1fcdb6

Please sign in to comment.