Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-django-phonenumber-field for 
openSUSE:Factory checked in at 2026-03-31 16:26:45
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-django-phonenumber-field (Old)
 and      /work/SRC/openSUSE:Factory/.python-django-phonenumber-field.new.1999 
(New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-django-phonenumber-field"

Tue Mar 31 16:26:45 2026 rev:8 rq:1343927 version:8.4.0

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/python-django-phonenumber-field/python-django-phonenumber-field.changes
  2025-10-13 15:37:10.177839975 +0200
+++ 
/work/SRC/openSUSE:Factory/.python-django-phonenumber-field.new.1999/python-django-phonenumber-field.changes
        2026-03-31 16:26:51.742334223 +0200
@@ -1,0 +2,8 @@
+Mon Mar 30 21:54:28 UTC 2026 - Dirk Müller <[email protected]>
+
+- update to 8.4.0:
+  * Handle empty values in `SplitPhoneNumberField` with
+    `max_length`
+  * Update supported Python and Django versions
+
+-------------------------------------------------------------------

Old:
----
  django_phonenumber_field-8.3.0.tar.gz

New:
----
  django_phonenumber_field-8.4.0.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-django-phonenumber-field.spec ++++++
--- /var/tmp/diff_new_pack.34qxeY/_old  2026-03-31 16:26:53.010387390 +0200
+++ /var/tmp/diff_new_pack.34qxeY/_new  2026-03-31 16:26:53.022387894 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package python-django-phonenumber-field
 #
-# Copyright (c) 2025 SUSE LLC and contributors
+# Copyright (c) 2026 SUSE LLC and contributors
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,7 +17,7 @@
 
 
 Name:           python-django-phonenumber-field
-Version:        8.3.0
+Version:        8.4.0
 Release:        0
 Summary:        International phone number field for django models
 License:        MIT
@@ -29,13 +29,13 @@
 BuildRequires:  %{python_module setuptools}
 BuildRequires:  fdupes
 BuildRequires:  python-rpm-macros
-Requires:       python-Babel
-Requires:       python-Django >= 4.2
+Requires:       python-Django >= 5.2
+Recommends:     python-Babel
 Recommends:     python-phonenumbers >= 7.0.2
 BuildArch:      noarch
 # SECTION test requirements
 BuildRequires:  %{python_module Babel}
-BuildRequires:  %{python_module Django >= 4.2}
+BuildRequires:  %{python_module Django >= 5.2}
 BuildRequires:  %{python_module django-rest-framework}
 BuildRequires:  %{python_module phonenumbers >= 7.0.2}
 BuildRequires:  %{python_module pytest}

++++++ django_phonenumber_field-8.3.0.tar.gz -> 
django_phonenumber_field-8.4.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/django_phonenumber_field-8.3.0/PKG-INFO 
new/django_phonenumber_field-8.4.0/PKG-INFO
--- old/django_phonenumber_field-8.3.0/PKG-INFO 2025-10-06 16:56:35.311564200 
+0200
+++ new/django_phonenumber_field-8.4.0/PKG-INFO 2025-11-24 16:09:16.992253000 
+0100
@@ -1,6 +1,6 @@
 Metadata-Version: 2.4
 Name: django-phonenumber-field
-Version: 8.3.0
+Version: 8.4.0
 Summary: An international phone number field for django models.
 Author-email: Stefan Foulis <[email protected]>, François Freitag 
<[email protected]>
 Maintainer-email: François Freitag <[email protected]>, Stefan Foulis 
<[email protected]>
@@ -13,23 +13,23 @@
 Classifier: Development Status :: 5 - Production/Stable
 Classifier: Framework :: Django
 Classifier: Framework :: Django :: 4.2
-Classifier: Framework :: Django :: 5.0
 Classifier: Framework :: Django :: 5.1
 Classifier: Framework :: Django :: 5.2
+Classifier: Framework :: Django :: 6.0
 Classifier: Intended Audience :: Developers
 Classifier: License :: OSI Approved :: MIT License
 Classifier: Operating System :: OS Independent
 Classifier: Programming Language :: Python
 Classifier: Programming Language :: Python :: 3
 Classifier: Programming Language :: Python :: 3 :: Only
-Classifier: Programming Language :: Python :: 3.9
 Classifier: Programming Language :: Python :: 3.10
 Classifier: Programming Language :: Python :: 3.11
 Classifier: Programming Language :: Python :: 3.12
 Classifier: Programming Language :: Python :: 3.13
+Classifier: Programming Language :: Python :: 3.14
 Classifier: Programming Language :: Python :: Implementation :: CPython
 Classifier: Topic :: Internet :: WWW/HTTP
-Requires-Python: >=3.9
+Requires-Python: >=3.10
 Description-Content-Type: text/x-rst
 License-File: LICENSE
 License-File: AUTHORS
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/django_phonenumber_field-8.3.0/django_phonenumber_field.egg-info/PKG-INFO 
new/django_phonenumber_field-8.4.0/django_phonenumber_field.egg-info/PKG-INFO
--- 
old/django_phonenumber_field-8.3.0/django_phonenumber_field.egg-info/PKG-INFO   
    2025-10-06 16:56:35.000000000 +0200
+++ 
new/django_phonenumber_field-8.4.0/django_phonenumber_field.egg-info/PKG-INFO   
    2025-11-24 16:09:16.000000000 +0100
@@ -1,6 +1,6 @@
 Metadata-Version: 2.4
 Name: django-phonenumber-field
-Version: 8.3.0
+Version: 8.4.0
 Summary: An international phone number field for django models.
 Author-email: Stefan Foulis <[email protected]>, François Freitag 
<[email protected]>
 Maintainer-email: François Freitag <[email protected]>, Stefan Foulis 
<[email protected]>
@@ -13,23 +13,23 @@
 Classifier: Development Status :: 5 - Production/Stable
 Classifier: Framework :: Django
 Classifier: Framework :: Django :: 4.2
-Classifier: Framework :: Django :: 5.0
 Classifier: Framework :: Django :: 5.1
 Classifier: Framework :: Django :: 5.2
+Classifier: Framework :: Django :: 6.0
 Classifier: Intended Audience :: Developers
 Classifier: License :: OSI Approved :: MIT License
 Classifier: Operating System :: OS Independent
 Classifier: Programming Language :: Python
 Classifier: Programming Language :: Python :: 3
 Classifier: Programming Language :: Python :: 3 :: Only
-Classifier: Programming Language :: Python :: 3.9
 Classifier: Programming Language :: Python :: 3.10
 Classifier: Programming Language :: Python :: 3.11
 Classifier: Programming Language :: Python :: 3.12
 Classifier: Programming Language :: Python :: 3.13
+Classifier: Programming Language :: Python :: 3.14
 Classifier: Programming Language :: Python :: Implementation :: CPython
 Classifier: Topic :: Internet :: WWW/HTTP
-Requires-Python: >=3.9
+Requires-Python: >=3.10
 Description-Content-Type: text/x-rst
 License-File: LICENSE
 License-File: AUTHORS
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/django_phonenumber_field-8.3.0/phonenumber_field/formfields.py 
new/django_phonenumber_field-8.4.0/phonenumber_field/formfields.py
--- old/django_phonenumber_field-8.3.0/phonenumber_field/formfields.py  
2025-10-06 16:54:33.000000000 +0200
+++ new/django_phonenumber_field-8.4.0/phonenumber_field/formfields.py  
2025-11-24 16:08:52.000000000 +0100
@@ -203,7 +203,7 @@
                         example_number=example_number,
                     )
         clean_value = super().clean(value)
-        if self.max_length is not None:
+        if clean_value not in self.empty_values and self.max_length is not 
None:
             phonenumber_str = clean_value.format_as(
                 getattr(settings, "PHONENUMBER_DB_FORMAT", "E164")
             )
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/django_phonenumber_field-8.3.0/phonenumber_field/modelfields.py 
new/django_phonenumber_field-8.4.0/phonenumber_field/modelfields.py
--- old/django_phonenumber_field-8.3.0/phonenumber_field/modelfields.py 
2025-10-06 16:54:33.000000000 +0200
+++ new/django_phonenumber_field-8.4.0/phonenumber_field/modelfields.py 
2025-11-24 16:08:52.000000000 +0100
@@ -1,5 +1,3 @@
-from typing import Optional
-
 from django.conf import settings
 from django.core import checks
 from django.db import models
@@ -120,7 +118,7 @@
         form_class=None,
         choices_form_class=None,
         **kwargs,
-    ) -> Optional[Field]:
+    ) -> Field | None:
         defaults = {
             "form_class": (
                 formfields.PhoneNumberField if form_class is None else 
form_class
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/django_phonenumber_field-8.3.0/phonenumber_field/version.py 
new/django_phonenumber_field-8.4.0/phonenumber_field/version.py
--- old/django_phonenumber_field-8.3.0/phonenumber_field/version.py     
2025-10-06 16:56:35.000000000 +0200
+++ new/django_phonenumber_field-8.4.0/phonenumber_field/version.py     
2025-11-24 16:09:16.000000000 +0100
@@ -28,7 +28,7 @@
 commit_id: COMMIT_ID
 __commit_id__: COMMIT_ID
 
-__version__ = version = '8.3.0'
-__version_tuple__ = version_tuple = (8, 3, 0)
+__version__ = version = '8.4.0'
+__version_tuple__ = version_tuple = (8, 4, 0)
 
-__commit_id__ = commit_id = 'g412517ceb'
+__commit_id__ = commit_id = 'g7e7d0fcf4'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/django_phonenumber_field-8.3.0/pyproject.toml 
new/django_phonenumber_field-8.4.0/pyproject.toml
--- old/django_phonenumber_field-8.3.0/pyproject.toml   2025-10-06 
16:54:33.000000000 +0200
+++ new/django_phonenumber_field-8.4.0/pyproject.toml   2025-11-24 
16:08:52.000000000 +0100
@@ -1,6 +1,6 @@
 [project]
 name = "django-phonenumber-field"
-requires-python = ">=3.9"
+requires-python = ">=3.10"
 description = "An international phone number field for django models."
 readme = "README.rst"
 authors = [
@@ -16,20 +16,20 @@
     "Development Status :: 5 - Production/Stable",
     "Framework :: Django",
     "Framework :: Django :: 4.2",
-    "Framework :: Django :: 5.0",
     "Framework :: Django :: 5.1",
     "Framework :: Django :: 5.2",
+    "Framework :: Django :: 6.0",
     "Intended Audience :: Developers",
     "License :: OSI Approved :: MIT License",
     "Operating System :: OS Independent",
     "Programming Language :: Python",
     "Programming Language :: Python :: 3",
     "Programming Language :: Python :: 3 :: Only",
-    "Programming Language :: Python :: 3.9",
     "Programming Language :: Python :: 3.10",
     "Programming Language :: Python :: 3.11",
     "Programming Language :: Python :: 3.12",
     "Programming Language :: Python :: 3.13",
+    "Programming Language :: Python :: 3.14",
     "Programming Language :: Python :: Implementation :: CPython",
     "Topic :: Internet :: WWW/HTTP",
 ]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/django_phonenumber_field-8.3.0/tests/models.py 
new/django_phonenumber_field-8.4.0/tests/models.py
--- old/django_phonenumber_field-8.3.0/tests/models.py  2025-10-06 
16:54:33.000000000 +0200
+++ new/django_phonenumber_field-8.4.0/tests/models.py  2025-11-24 
16:08:52.000000000 +0100
@@ -106,5 +106,9 @@
     phone = PhoneNumberField(region="AR", blank=True, null=True)
 
 
-class PhoneNumberWithMaxLength(models.Model):
-    phone = PhoneNumberField(max_length=3)
+class PhoneNumberWithMaxLengthDefault(models.Model):
+    phone = PhoneNumberField(max_length=12, blank=True, default="")
+
+
+class PhoneNumberWithMaxLengthNullable(models.Model):
+    phone = PhoneNumberField(max_length=12, blank=True, null=True)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/django_phonenumber_field-8.3.0/tests/test_formfields.py 
new/django_phonenumber_field-8.4.0/tests/test_formfields.py
--- old/django_phonenumber_field-8.3.0/tests/test_formfields.py 2025-10-06 
16:54:33.000000000 +0200
+++ new/django_phonenumber_field-8.4.0/tests/test_formfields.py 2025-11-24 
16:08:52.000000000 +0100
@@ -12,7 +12,11 @@
 from phonenumber_field.formfields import PhoneNumberField, 
SplitPhoneNumberField
 from phonenumber_field.phonenumber import PhoneNumber
 from phonenumber_field.validators import validate_phonenumber
-from tests.models import NullablePhoneNumber, PhoneNumberWithMaxLength
+from tests.models import (
+    NullablePhoneNumber,
+    PhoneNumberWithMaxLengthDefault,
+    PhoneNumberWithMaxLengthNullable,
+)
 
 ALGERIAN_PHONE_NUMBER = "+213799136332"
 
@@ -724,24 +728,49 @@
         self.assertIs(form.is_valid(), True)
         self.assertEqual(form.cleaned_data["phone_number"], "+33612345678")
 
-    def test_formfield_with_max_length(self):
-        class TestForm(forms.Form):
-            def __init__(self, *args, **kwargs):
-                super().__init__(*args, **kwargs)
-                self.fields = forms.fields_for_model(
-                    PhoneNumberWithMaxLength,
-                    ["phone"],
-                    field_classes={"phone": SplitPhoneNumberField},
-                )
+    def test_formfield_with_max_length_default(self):
+        def make_form(model):
+            class TestForm(forms.Form):
+                def __init__(self, *args, **kwargs):
+                    super().__init__(*args, **kwargs)
+                    self.fields = forms.fields_for_model(
+                        model,
+                        ["phone"],
+                        field_classes={"phone": SplitPhoneNumberField},
+                    )
 
-        form = TestForm(data={"phone_0": "FR", "phone_1": "33612345678"})
-        self.assertIs(form.is_valid(), False)
-        self.assertEqual(
-            form.errors,
-            {
-                "phone": [
-                    "Ensure this value has no more than 3 characters, "
-                    "“6 12 34 56 78” is 13 characters long."
-                ],
-            },
-        )
+            return TestForm
+
+        for model, empty_value in [
+            (PhoneNumberWithMaxLengthDefault, ""),
+            (PhoneNumberWithMaxLengthNullable, None),
+        ]:
+            TestForm = make_form(model)
+
+            with self.subTest("no data", model=model):
+                form = TestForm(data={})
+                self.assertIs(form.is_valid(), True)
+                self.assertEqual(form.cleaned_data["phone"], empty_value)
+
+            with self.subTest("empty phone number", model=model):
+                form = TestForm(data={"phone_0": "", "phone_1": ""})
+                self.assertIs(form.is_valid(), True)
+                self.assertEqual(form.cleaned_data["phone"], empty_value)
+
+            with self.subTest("phone number within max_length", model=model):
+                form = TestForm(data={"phone_0": "AU", "phone_1": 
"0444444444"})
+                self.assertIs(form.is_valid(), True)
+                self.assertEqual(form.cleaned_data["phone"], "+61444444444")
+
+            with self.subTest("phone number exceeding max_length", 
model=model):
+                form = TestForm(data={"phone_0": "FR", "phone_1": 
"33612345678"})
+                self.assertIs(form.is_valid(), False)
+                self.assertEqual(
+                    form.errors,
+                    {
+                        "phone": [
+                            "Ensure this value has no more than 12 characters, 
"
+                            "“6 12 34 56 78” is 13 characters long."
+                        ],
+                    },
+                )
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/django_phonenumber_field-8.3.0/tox.ini 
new/django_phonenumber_field-8.4.0/tox.ini
--- old/django_phonenumber_field-8.3.0/tox.ini  2025-10-06 16:54:33.000000000 
+0200
+++ new/django_phonenumber_field-8.4.0/tox.ini  2025-11-24 16:08:52.000000000 
+0100
@@ -2,30 +2,29 @@
 envlist =
     ruff
     dj42
-    dj50
     dj51
     dj52
+    dj60
     djmain
 isolated_build = true
 minversion = 1.9
 
 [gh]
 python =
-    3.9 = dj42
-    3.10 = dj{42,50,51,52}
-    3.11 = dj{42,50,51,52}
-    3.12 = dj{42,50,51,52,main}
-    3.13 = dj{42,50,51,52,main}
-    3.14 = djmain
+    3.10 = dj{42,51,52}
+    3.11 = dj{42,51,52}
+    3.12 = dj{42,51,52,60,main}
+    3.13 = dj{42,51,52,60,main}
+    3.14 = dj{52,60,main}
 
 [testenv]
 deps =
     babel
     coverage
     dj42: Django>=4.2,<4.3
-    dj50: Django>=5.0b1,<5.1
     dj51: Django>=5.1b1,<5.2
     dj52: Django>=5.2a1,<5.3
+    dj60: Django>=6.0a1,<6.1
     djmain: https://github.com/django/django/archive/main.tar.gz
     djangorestframework
 extras = phonenumberslite

Reply via email to