www/py-django-assets: Add compatibility for Django 4.x
* Add an upstream patch that adds compatibility for Python 3.11 as well while I'm here. PR: 276319
This commit is contained in:
parent
1133b74a36
commit
164c5e98aa
|
@ -1,6 +1,6 @@
|
|||
PORTNAME= django-assets
|
||||
PORTVERSION= 2.0
|
||||
PORTREVISION= 1
|
||||
PORTREVISION= 2
|
||||
CATEGORIES= www python
|
||||
MASTER_SITES= PYPI
|
||||
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
|
||||
|
@ -14,7 +14,8 @@ LICENSE= BSD2CLAUSE
|
|||
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}django32>=1.7:www/py-django32@${PY_FLAVOR} \
|
||||
${PYTHON_PKGNAMEPREFIX}webassets>=2.0:www/py-webassets@${PY_FLAVOR}
|
||||
|
||||
USES= python
|
||||
USES= dos2unix python
|
||||
DOS2UNIX_FILES= django_assets/management/commands/assets.py
|
||||
USE_PYTHON= autoplist distutils
|
||||
|
||||
NO_ARCH= yes
|
||||
|
|
|
@ -0,0 +1,20 @@
|
|||
From: Jonatan Heyman <jonatan@heyman.info>
|
||||
Date: Thu, 10 Nov 2022 23:26:07 +0100
|
||||
Subject: [PATCH] Global regex flags must be at the start of regex in Python
|
||||
3.11
|
||||
|
||||
Obtained from:
|
||||
|
||||
https://patch-diff.githubusercontent.com/raw/miracle2k/django-assets/pull/104.patch
|
||||
|
||||
--- django_assets/glob.py.orig 2018-02-23 09:54:00 UTC
|
||||
+++ django_assets/glob.py
|
||||
@@ -121,7 +121,7 @@ def translate(pat):
|
||||
res = '%s([%s])' % (res, stuff)
|
||||
else:
|
||||
res = res + re.escape(c)
|
||||
- return res + '\Z(?ms)'
|
||||
+ return '(?ms)' + res + '\Z'
|
||||
|
||||
|
||||
"""Filename globbing utility."""
|
|
@ -0,0 +1,19 @@
|
|||
From: Madison Swain-Bowden <bowdenm@spu.edu>
|
||||
Date: Sat, 5 Nov 2022 14:08:05 -0700
|
||||
Subject: [PATCH] Fix issue with running in Django 4.1
|
||||
|
||||
Obtained from:
|
||||
|
||||
https://patch-diff.githubusercontent.com/raw/miracle2k/django-assets/pull/103.patch
|
||||
|
||||
--- django_assets/management/commands/assets.py.orig 2024-03-24 15:11:16 UTC
|
||||
+++ django_assets/management/commands/assets.py
|
||||
@@ -37,7 +37,7 @@ class Command(BaseCommand):
|
||||
|
||||
class Command(BaseCommand):
|
||||
help = 'Manage assets.'
|
||||
- requires_system_checks = False
|
||||
+ requires_system_checks = []
|
||||
|
||||
def add_arguments(self, parser):
|
||||
# parser.add_argument('poll_id', nargs='+', type=str)
|
Loading…
Reference in New Issue