Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package python-Django for openSUSE:Factory checked in at 2025-07-31 17:44:58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-Django (Old) and /work/SRC/openSUSE:Factory/.python-Django.new.1944 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-Django" Thu Jul 31 17:44:58 2025 rev:135 rq:1296418 version:5.2.4 Changes: -------- --- /work/SRC/openSUSE:Factory/python-Django/python-Django.changes 2025-07-20 15:29:55.326180066 +0200 +++ /work/SRC/openSUSE:Factory/.python-Django.new.1944/python-Django.changes 2025-07-31 17:45:04.569350082 +0200 @@ -1,0 +2,7 @@ +Wed Jul 30 06:03:44 UTC 2025 - Steve Kowalik <steven.kowa...@suse.com> + +- Add patch support-msgfmt-0.25.patch: + * Support msgfmt 0.25 error messages changes. (bsc#1246966) +- Remove unneeded Requires on tzdata. + +------------------------------------------------------------------- New: ---- support-msgfmt-0.25.patch ----------(New B)---------- New: - Add patch support-msgfmt-0.25.patch: * Support msgfmt 0.25 error messages changes. (bsc#1246966) ----------(New E)---------- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-Django.spec ++++++ --- /var/tmp/diff_new_pack.gcJQzZ/_old 2025-07-31 17:45:05.493388487 +0200 +++ /var/tmp/diff_new_pack.gcJQzZ/_new 2025-07-31 17:45:05.497388653 +0200 @@ -32,6 +32,8 @@ Source99: python-Django-rpmlintrc # PATCH-FIX-UPSTREAM https://github.com/django/django/pull/19639 Fixed #36499 -- Adjusted utils_tests.test_html.TestUtilsHtml.test_strip_tags following Python's HTMLParser new behavior. Patch0: test_strip_tags.patch +# PATCH-FIX-UPSTREAM https://github.com/django/django/pull/19530 Fixed #36421 -- Made test_msgfmt_error_including_non_ascii compatible with with msgfmt 0.25. +Patch1: support-msgfmt-0.25.patch BuildRequires: %{python_module Jinja2 >= 2.9.2} BuildRequires: %{python_module Pillow >= 6.2.0} BuildRequires: %{python_module PyYAML} @@ -55,7 +57,6 @@ Requires: python Requires: python-asgiref >= 3.7.0 Requires: python-sqlparse >= 0.3.1 -Requires: python-tzdata Requires(post): update-alternatives Requires(postun): update-alternatives Recommends: python-Jinja2 >= 2.9.2 ++++++ support-msgfmt-0.25.patch ++++++ >From 3609c463a4cfc5a7e76f4d4ba008c5096b1f1437 Mon Sep 17 00:00:00 2001 From: Jericho Serrano <118679068+jericho1...@users.noreply.github.com> Date: Fri, 6 Jun 2025 04:58:29 +0800 Subject: [PATCH] Fixed #36421 -- Made test_msgfmt_error_including_non_ascii compatible with msgfmt 0.25. --- tests/i18n/test_compilation.py | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/tests/i18n/test_compilation.py b/tests/i18n/test_compilation.py index 4b0bb9f6bb1..3a57dbf0765 100644 --- a/tests/i18n/test_compilation.py +++ b/tests/i18n/test_compilation.py @@ -1,5 +1,6 @@ import gettext as gettext_module import os +import re import stat import unittest from io import StringIO @@ -8,10 +9,12 @@ from unittest import mock from django.core.management import CommandError, call_command, execute_from_command_line -from django.core.management.utils import find_command +from django.core.management.utils import find_command, popen_wrapper from django.test import SimpleTestCase, override_settings from django.test.utils import captured_stderr, captured_stdout from django.utils import translation +from django.utils.encoding import DEFAULT_LOCALE_ENCODING +from django.utils.functional import cached_property from django.utils.translation import gettext from .utils import RunInTmpDirMixin, copytree @@ -254,6 +257,17 @@ def test_no_dirs_accidentally_skipped(self): class CompilationErrorHandling(MessageCompilationTests): + @cached_property + def msgfmt_version(self): + # Note that msgfmt is installed via GNU gettext tools, hence the msgfmt + # version should align to gettext. + out, err, status = popen_wrapper( + ["msgfmt", "--version"], + stdout_encoding=DEFAULT_LOCALE_ENCODING, + ) + m = re.search(r"(\d+)\.(\d+)\.?(\d+)?", out) + return tuple(int(d) for d in m.groups() if d is not None) + def test_error_reported_by_msgfmt(self): # po file contains wrong po formatting. with self.assertRaises(CommandError): @@ -278,7 +292,14 @@ def test_msgfmt_error_including_non_ascii(self): call_command( "compilemessages", locale=["ko"], stdout=StringIO(), stderr=stderr ) - self.assertIn("' cannot start a field name", stderr.getvalue()) + if self.msgfmt_version < (0, 25): + error_msg = "' cannot start a field name" + else: + error_msg = ( + "a field name starts with a character that is not alphanumerical " + "or underscore" + ) + self.assertIn(error_msg, stderr.getvalue()) class ProjectAndAppTests(MessageCompilationTests):