Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop Python 3.6 #458

Merged
merged 6 commits into from May 30, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/test-suite.yml
Expand Up @@ -14,7 +14,7 @@ jobs:

strategy:
matrix:
python-version: ["3.6", "3.7", "3.8", "3.9", "3.10"]
python-version: ["3.7", "3.8", "3.9", "3.10"]

services:
mysql:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -19,7 +19,7 @@ Databases is suitable for integrating against any async Web framework, such as [

**Documentation**: [https://www.encode.io/databases/](https://www.encode.io/databases/)

**Requirements**: Python 3.6+
**Requirements**: Python 3.7+

---

Expand Down
7 changes: 1 addition & 6 deletions databases/core.py
Expand Up @@ -2,8 +2,8 @@
import contextlib
import functools
import logging
import sys
import typing
from contextvars import ContextVar
from types import TracebackType
from urllib.parse import SplitResult, parse_qsl, unquote, urlsplit

Expand All @@ -13,11 +13,6 @@
from databases.importer import import_from_string
from databases.interfaces import DatabaseBackend, Record

if sys.version_info >= (3, 7): # pragma: no cover
from contextvars import ContextVar
else: # pragma: no cover
from aiocontextvars import ContextVar

try: # pragma: no cover
import click

Expand Down
2 changes: 1 addition & 1 deletion docs/index.md
Expand Up @@ -17,7 +17,7 @@ expression language, and provides support for PostgreSQL, MySQL, and SQLite.
Databases is suitable for integrating against any async Web framework, such as [Starlette][starlette],
[Sanic][sanic], [Responder][responder], [Quart][quart], [aiohttp][aiohttp], [Tornado][tornado], or [FastAPI][fastapi].

**Requirements**: Python 3.6+
**Requirements**: Python 3.7+

---

Expand Down
7 changes: 2 additions & 5 deletions requirements.txt
@@ -1,11 +1,8 @@
# Notes...
# The JSONField tests require sqlalchemy 1.3+. Other cases work at lower versions.
# The aiocontextvars package is only required as a backport for Python 3.6.
-e .

# Async database drivers
asyncmy;python_version>"3.6"
aiomysql;python_version<"3.10"
asyncmy
aiomysql
aiopg
aiosqlite
asyncpg
Expand Down
5 changes: 2 additions & 3 deletions setup.py
Expand Up @@ -37,7 +37,7 @@ def get_packages(package):
setup(
name="databases",
version=get_version("databases"),
python_requires=">=3.6",
python_requires=">=3.7",
url="https://github.com/encode/databases",
license="BSD",
description="Async database support for Python.",
Expand All @@ -47,7 +47,7 @@ def get_packages(package):
author_email="tom@tomchristie.com",
packages=get_packages("databases"),
package_data={"databases": ["py.typed"]},
install_requires=["sqlalchemy>=1.4,<1.5", 'aiocontextvars;python_version<"3.7"'],
install_requires=["sqlalchemy>=1.4,<1.5"],
extras_require={
"postgresql": ["asyncpg"],
"asyncpg": ["asyncpg"],
Expand All @@ -66,7 +66,6 @@ def get_packages(package):
"Operating System :: OS Independent",
"Topic :: Internet :: WWW/HTTP",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
Expand Down