diff --git a/.builds/py311-alpine.yml b/.builds/py311-alpine.yml index 3ea2d5f..11febef 100644 --- a/.builds/py311-alpine.yml +++ b/.builds/py311-alpine.yml @@ -26,15 +26,9 @@ tasks: - tox-sqlite: | cd django-afip tox -e sqlite - - tox-django42-mariadb: | - cd django-afip - tox -e django42-mysql - tox-django50-mariadb: | cd django-afip tox -e django50-mysql - - tox-django42-postgres: | - cd django-afip - tox -e django42-postgres - tox-django50-postgres: | cd django-afip tox -e django50-postgres diff --git a/.builds/py312+live-alpine.yml b/.builds/py312+live-alpine.yml index f29783c..f4110ba 100644 --- a/.builds/py312+live-alpine.yml +++ b/.builds/py312+live-alpine.yml @@ -26,15 +26,9 @@ tasks: - tox-sqlite: | cd django-afip tox -e sqlite - - tox-django42-mariadb: | - cd django-afip - tox -e django42-mysql - tox-django50-mariadb: | cd django-afip tox -e django50-mysql - - tox-django42-postgres: | - cd django-afip - tox -e django42-postgres - tox-django50-postgres: | cd django-afip tox -e django50-postgres diff --git a/django_afip/migrations/0011_receiptentry_discount_and_more.py b/django_afip/migrations/0011_receiptentry_discount_and_more.py index dfacb00..c12e3a3 100644 --- a/django_afip/migrations/0011_receiptentry_discount_and_more.py +++ b/django_afip/migrations/0011_receiptentry_discount_and_more.py @@ -29,14 +29,14 @@ class Migration(migrations.Migration): migrations.AddConstraint( model_name="receiptentry", constraint=models.CheckConstraint( - check=models.Q(("discount__gte", Decimal("0.0"))), + condition=models.Q(("discount__gte", Decimal("0.0"))), name="discount_positive_value", ), ), migrations.AddConstraint( model_name="receiptentry", constraint=models.CheckConstraint( - check=models.Q( + condition=models.Q( ( "discount__lte", django.db.models.expressions.CombinedExpression( diff --git a/django_afip/models.py b/django_afip/models.py index 4b5e87e..c45a311 100644 --- a/django_afip/models.py +++ b/django_afip/models.py @@ -1693,10 +1693,11 @@ class Meta: verbose_name_plural = _("receipt entries") constraints = ( CheckConstraint( - check=Q(discount__gte=Decimal("0.0")), name="discount_positive_value" + condition=Q(discount__gte=Decimal("0.0")), + name="discount_positive_value", ), CheckConstraint( - check=Q(discount__lte=F("quantity") * F("unit_price")), + condition=Q(discount__lte=F("quantity") * F("unit_price")), name="discount_less_than_total", ), ) diff --git a/docs/changelog.rst b/docs/changelog.rst index 045d811..932123c 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -21,6 +21,7 @@ Any breaking changes which require intervention will be mentioned here. - Extend supported versions of ``django-renderpdf``, ``qrcode`` and ``cryptography``. - Drop support for Python 3.9. +* Dropped support for Django 4.2. 13.2.2 ------ diff --git a/pyproject.toml b/pyproject.toml index e7d4b10..c2e7925 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -13,7 +13,6 @@ classifiers = [ "Development Status :: 6 - Mature", "Environment :: Web Environment", "Framework :: Django", - "Framework :: Django :: 4.2", "Framework :: Django :: 5.0", "Framework :: Django :: 5.1", "Framework :: Django :: 5.2", @@ -30,7 +29,7 @@ classifiers = [ ] dependencies = [ "cryptography>=3.2,<47", - "django>=4.2,<5.3", + "django>=5.0,<5.3", "django_renderpdf>=6.0.0,<7.0.0", "lxml>=3.4.4", "pyopenssl>=16.2.0", diff --git a/tox.ini b/tox.ini index 92db000..da451fd 100644 --- a/tox.ini +++ b/tox.ini @@ -7,7 +7,6 @@ extras = postgres: postgres mysql: mysql deps = - django42: Django>=4.0,<4.2 django50: Django>=5.0,<5.1 django51: Django>=5.1,<5.2 django52: Django>=5.2,<5.3