Skip to content
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ jobs:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.10
- name: Set up Python 3.13
uses: actions/setup-python@v4
with:
python-version: "3.10"
python-version: "3.13"
- name: "Install Dependencies"
run: pip install flake8
- name: Lint
Expand All @@ -26,10 +26,10 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12", "pypy3.10"]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13", "pypy3.10"]
experimental: [false]
include:
- python-version: "3.11"
- python-version: "3.13"
experimental: true

services:
Expand Down Expand Up @@ -67,6 +67,6 @@ jobs:
run: pip install tox tox-gh-actions

- name: "Run tests"
run: tox ${{ matrix.experimental && '-e py311-djmain' || '' }}
run: tox ${{ matrix.experimental && '-e py313-djmain' || '' }}
env:
MYSQL_HOST: 127.0.0.1
9 changes: 8 additions & 1 deletion cacheops/tree.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,20 @@
from django.db.models.sql import OR
from django.db.models.sql.datastructures import Join
from django.db.models.sql.query import Query, ExtraWhere
from django.db.models.sql.where import NothingNode, SubqueryConstraint
from django.db.models.sql.where import NothingNode
from django.db.models.lookups import Lookup, Exact, In, IsNull
from django.db.models.expressions import BaseExpression, Exists

from .conf import settings
from .invalidation import serializable_fields

# This existed prior to Django 5.2
try:
from django.db.models.sql.where import SubqueryConstraint
except ImportError:
class SubqueryConstraint(object):
pass


def dnfs(qs):
"""
Expand Down
4 changes: 2 additions & 2 deletions requirements-test.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
pytest==8.3.3
pytest-django==4.5.2
pytest==8.3.5
pytest-django==4.11.1
django>=3.2
redis>=3.0.0
funcy>=1.8
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
Expand All @@ -45,6 +44,7 @@
'Framework :: Django :: 4.1',
'Framework :: Django :: 4.2',
'Framework :: Django :: 5.0',
'Framework :: Django :: 5.2',

'Environment :: Web Environment',
'Intended Audience :: Developers',
Expand Down
13 changes: 7 additions & 6 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
[tox]
envlist =
lint,
py37-dj32,
py{38,39}-dj{32,40},
py310-dj{32,40,41},
py311-dj{41,42,50},
py312-dj{42,50},
py312-dj{42,50,52},
py313-dj{42,50,52},
pypy310-dj40

[gh-actions]
python =
3.7: py37
3.8: py38
3.9: py39
3.10: py310
3.11: py311
3.12: py312
3.13: py313
pypy-3.10: pypy310


Expand All @@ -27,16 +27,17 @@ setenv =
CPLUS_INCLUDE_PATH=/usr/include/gdal
C_INCLUDE_PATH=/usr/include/gdal
deps =
pytest
pytest-django
pytest==8.3.5
pytest-django==4.11.1
dj32: Django>=3.2,<3.3
dj40: Django>=4.0,<4.1
dj41: Django>=4.1,<4.2
dj42: Django>=4.2.8,<5.0
dj50: Django>=5.0,<5.1
dj52: Django>=5.2,<5.3
djmain: git+https://github.com/django/django
mysqlclient
py{37,38,39,310,311,312}: psycopg2-binary
py{38,39,310,311,312,313}: psycopg2-binary
; gdal=={env:GDAL_VERSION:2.4}
pypy310: psycopg2cffi>=2.7.6
before_after==1.0.0
Expand Down