git: 57b280ae7e84 - main - www/py-django-timezone-field: Update to 5.1

From: Kai Knoblich <kai_at_FreeBSD.org>
Date: Tue, 27 Jun 2023 08:27:50 UTC
The branch main has been updated by kai:

URL: https://cgit.FreeBSD.org/ports/commit/?id=57b280ae7e844a5621a2e0ad2cca6ee52501f524

commit 57b280ae7e844a5621a2e0ad2cca6ee52501f524
Author:     Kai Knoblich <kai@FreeBSD.org>
AuthorDate: 2023-06-27 08:26:14 +0000
Commit:     Kai Knoblich <kai@FreeBSD.org>
CommitDate: 2023-06-27 08:26:14 +0000

    www/py-django-timezone-field: Update to 5.1
    
    * Switch to PEP-517 build and remove no longer required patch.
    
    Changelog:
    
    https://github.com/mfogel/django-timezone-field/compare/5.0...5.1
---
 www/py-django-timezone-field/Makefile              |  7 +++---
 www/py-django-timezone-field/distinfo              |  6 ++---
 .../files/patch-timezone__field_fields.py          | 27 ----------------------
 3 files changed, 7 insertions(+), 33 deletions(-)

diff --git a/www/py-django-timezone-field/Makefile b/www/py-django-timezone-field/Makefile
index cb1dc979990c..fec42e7aebfc 100644
--- a/www/py-django-timezone-field/Makefile
+++ b/www/py-django-timezone-field/Makefile
@@ -1,9 +1,9 @@
 PORTNAME=	django-timezone-field
-DISTVERSION=	5.0
-PORTREVISION=	2
+DISTVERSION=	5.1
 CATEGORIES=	www python
 MASTER_SITES=	PYPI
 PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
+DISTNAME=	django_timezone_field-${DISTVERSION}
 
 MAINTAINER=	kai@FreeBSD.org
 COMMENT=	Provides database and form fields for pytz timezone objects for Django
@@ -12,11 +12,12 @@ WWW=		https://github.com/mfogel/django-timezone-field
 LICENSE=	BSD2CLAUSE
 LICENSE_FILE=	${WRKSRC}/LICENSE.txt
 
+BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}poetry-core>=1.0.0:devel/py-poetry-core@${PY_FLAVOR}
 RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}django32>=2.2:www/py-django32@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}pytz>0:devel/py-pytz@${PY_FLAVOR}
 
 USES=		python:3.7+
-USE_PYTHON=	distutils autoplist
+USE_PYTHON=	autoplist pep517
 
 NO_ARCH=		yes
 CONFLICTS_INSTALL=	${PYTHON_PKGNAMEPREFIX}*${PORTNAME}
diff --git a/www/py-django-timezone-field/distinfo b/www/py-django-timezone-field/distinfo
index 8933b4e95c22..d2242caf5e48 100644
--- a/www/py-django-timezone-field/distinfo
+++ b/www/py-django-timezone-field/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1645108464
-SHA256 (django-timezone-field-5.0.tar.gz) = 15746ed367a5a32eda76cfa2886eeec1de8cda79f519b7c5e12f87ed7cdbd663
-SIZE (django-timezone-field-5.0.tar.gz) = 11838
+TIMESTAMP = 1687762789
+SHA256 (django_timezone_field-5.1.tar.gz) = 73fc49519273cd5da1c7f16abc04a4bcad87b00cc02968d0d384c0fecf9a8a86
+SIZE (django_timezone_field-5.1.tar.gz) = 11525
diff --git a/www/py-django-timezone-field/files/patch-timezone__field_fields.py b/www/py-django-timezone-field/files/patch-timezone__field_fields.py
deleted file mode 100644
index 72b10b78da49..000000000000
--- a/www/py-django-timezone-field/files/patch-timezone__field_fields.py
+++ /dev/null
@@ -1,27 +0,0 @@
-From 0257f2e9c7c488e8a859ee924c93d9f38afa4dc7 Mon Sep 17 00:00:00 2001
-From: jeremystretch <jstretch@ns1.com>
-Date: Fri, 12 Aug 2022 10:03:27 -0400
-Subject: [PATCH] Fixes #94: Catch ZoneInfoNotFoundError exception when
- populating timezones
-
-Obtained from:
-
-https://github.com/mfogel/django-timezone-field/commit/0257f2e9c7c488e8a859ee924c93d9f38afa4dc7
-
---- timezone_field/fields.py.orig	2022-02-09 04:42:10 UTC
-+++ timezone_field/fields.py
-@@ -38,7 +38,13 @@ class TimeZoneField(models.Field):
-     #       existing migration files will need to be accomodated.
-     default_max_length = 63
-     default_pytz_tzs = [pytz.timezone(tz) for tz in pytz.common_timezones]
--    default_zoneinfo_tzs = [ZoneInfo(tz) for tz in pytz.common_timezones]
-+    default_zoneinfo_tzs = []
-+    for tz in pytz.common_timezones:
-+        try:
-+            default_zoneinfo_tzs.append(ZoneInfo(tz))
-+        except ZoneInfoNotFoundError:
-+            # ZoneInfo does not yet exist for this timezone
-+            pass
- 
-     def __init__(self, *args, **kwargs):
-         # allow some use of positional args up until the args we customize