diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 871557a..b20034e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -20,11 +20,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: - - "3.7" - - "3.8" - - "3.9" - - "3.10" + python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"] fail-fast: false steps: @@ -56,6 +52,7 @@ jobs: if: steps.cache.outputs.cache-hit != 'true' run: python -m poetry install - name: Lint + if: ${{ matrix.python-version != '3.7' }} run: python -m poetry run bash scripts/lint.sh - run: mkdir coverage - name: Test diff --git a/README.md b/README.md index f85bb97..df1e390 100644 --- a/README.md +++ b/README.md @@ -50,7 +50,7 @@ It combines SQLAlchemy and Pydantic and tries to simplify the code you write as ## Requirements -A recent and currently supported version of Python Python. +A recent and currently supported version of Python (right now, Python supports versions 3.7 and above). As **SQLModel** is based on **Pydantic** and **SQLAlchemy**, it requires them. They will be automatically installed when you install SQLModel. diff --git a/docs/contributing.md b/docs/contributing.md index 1cd62d4..90babf1 100644 --- a/docs/contributing.md +++ b/docs/contributing.md @@ -6,6 +6,10 @@ First, you might want to see the basic ways to [help SQLModel and get help](help If you already cloned the repository and you know that you need to deep dive in the code, here are some guidelines to set up your environment. +### Python + +SQLModel supports Python 3.7 and above, but for development you should have at least **Python 3.7**. + ### Poetry **SQLModel** uses Poetry to build, package, and publish the project. diff --git a/docs/features.md b/docs/features.md index 102edef..2d5e11d 100644 --- a/docs/features.md +++ b/docs/features.md @@ -12,7 +12,7 @@ Nevertheless, SQLModel is completely **independent** of FastAPI and can be used ## Just Modern Python -It's all based on standard modern **Python** type annotations. No new syntax to learn. Just standard modern Python. +It's all based on standard modern **Python** type annotations. No new syntax to learn. Just standard modern Python. If you need a 2 minute refresher of how to use Python types (even if you don't use SQLModel or FastAPI), check the FastAPI tutorial section: Python types intro. diff --git a/docs/index.md b/docs/index.md index f85bb97..df1e390 100644 --- a/docs/index.md +++ b/docs/index.md @@ -50,7 +50,7 @@ It combines SQLAlchemy and Pydantic and tries to simplify the code you write as ## Requirements -A recent and currently supported version of Python Python. +A recent and currently supported version of Python (right now, Python supports versions 3.7 and above). As **SQLModel** is based on **Pydantic** and **SQLAlchemy**, it requires them. They will be automatically installed when you install SQLModel. diff --git a/docs/tutorial/index.md b/docs/tutorial/index.md index 79fa670..4d89fac 100644 --- a/docs/tutorial/index.md +++ b/docs/tutorial/index.md @@ -64,6 +64,8 @@ $ cd sqlmodel-tutorial Make sure you have an officially supported version of Python. +Currently it is **Python 3.7** and above (Python 3.6 was already deprecated). + You can check which version you have with:
@@ -82,6 +84,7 @@ You might want to try with the specific versions, for example with: * `python3.10` * `python3.9` * `python3.8` +* `python3.7` The code would look like this: diff --git a/pyproject.toml b/pyproject.toml index 3876d74..4f44ac3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -21,6 +21,7 @@ classifiers = [ "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", + "Programming Language :: Python :: 3.11", "Topic :: Database", "Topic :: Database :: Database Engines/Servers", "Topic :: Internet", @@ -49,6 +50,8 @@ fastapi = "^0.68.1" requests = "^2.26.0" autoflake = "^1.4" isort = "^5.9.3" +async_generator = {version = "*", python = "~3.7"} +async-exit-stack = {version = "*", python = "~3.7"} [build-system] requires = ["poetry-core"]