Skip to content

Commit

Permalink
add support for Python 3.12 (except dropbox) and Django 5.0
Browse files Browse the repository at this point in the history
Co-authored-by: RachellCalhoun <[email protected]>
Co-authored-by: AmiZya <[email protected]>
  • Loading branch information
3 people committed Nov 26, 2023
1 parent 93d5ef2 commit ff7fbf5
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 1 deletion.
14 changes: 14 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,28 @@ jobs:
- "3.9"
- "3.10"
- "3.11"
- "3.12"
django-version:
- "3.2"
- "4.1"
- "4.2"
- "5.0"
- "main"
exclude:
- python-version: "3.7"
django-version: "4.1"
- python-version: "3.12"
django-version: "4.1"
- python-version: "3.7"
django-version: "4.2"
- python-version: "3.12"
django-version: "4.2"
- python-version: "3.7"
django-version: "5.0"
- python-version: "3.8"
django-version: "5.0"
- python-version: "3.9"
django-version: "5.0"
- python-version: "3.7"
django-version: "main"
- python-version: "3.8"
Expand All @@ -39,6 +51,8 @@ jobs:
django-version: "main"
- python-version: "3.11"
django-version: "3.2"
- python-version: "3.12"
django-version: "3.2"

steps:
- uses: actions/checkout@v4
Expand Down
4 changes: 3 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ classifiers = [
"Framework :: Django :: 3.2",
"Framework :: Django :: 4.1",
"Framework :: Django :: 4.2",
"Framework :: Django :: 5.0",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
Expand All @@ -32,6 +33,7 @@ classifiers = [
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
]
dynamic = [
"readme",
Expand All @@ -49,7 +51,7 @@ boto3 = [
"boto3>=1.4.4",
]
dropbox = [
"dropbox>=7.2.1",
"dropbox>=7.2.1; python_version<'3.12'",
]
google = [
"google-cloud-storage>=1.27",
Expand Down
8 changes: 8 additions & 0 deletions tests/test_dropbox.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
import io
import sys
from datetime import datetime
from unittest import SkipTest
from unittest import mock

if sys.version_info >= (3, 12, 0):
raise SkipTest(
"dropbox library does not support Python 3.12+. "
"Skipping all tests in test_dropbox.py"
)

from django.core.exceptions import ImproperlyConfigured
from django.core.exceptions import SuspiciousFileOperation
from django.core.files.base import File
Expand Down
2 changes: 2 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ envlist =
py{3.7,3.8,3.9,3.10}-django3.2
py{3.8,3.9,3.10,3.11}-django4.1
py{3.8,3.9,3.10,3.11}-django4.2
py{3.10,3.11,3.12}-django5.0
py{3.10,3.11,3.12}-djangomain
ruff

Expand All @@ -18,6 +19,7 @@ deps =
django3.2: django~=3.2.9
django4.1: django~=4.1.0
django4.2: django~=4.2.0
django5.0: django~=5.0b1
djangomain: https://github.com/django/django/archive/main.tar.gz
moto
pytest
Expand Down

0 comments on commit ff7fbf5

Please sign in to comment.