public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/protobuf-python/, dev-python/protobuf-python/files/
Date: Thu, 13 Jun 2024 04:53:51 +0000 (UTC)	[thread overview]
Message-ID: <1718254380.de15b02f0b35c97ba57195624a582d191b038812.sam@gentoo> (raw)

commit:     de15b02f0b35c97ba57195624a582d191b038812
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Thu Jun 13 04:52:49 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Jun 13 04:53:00 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=de15b02f

dev-python/protobuf-python: fix tests

Bug: https://bugs.gentoo.org/934062
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../files/protobuf-python-4.22.5-python.patch       | 21 +++++++++++++++++++++
 .../protobuf-python/protobuf-python-4.22.5.ebuild   |  1 +
 2 files changed, 22 insertions(+)

diff --git a/dev-python/protobuf-python/files/protobuf-python-4.22.5-python.patch b/dev-python/protobuf-python/files/protobuf-python-4.22.5-python.patch
new file mode 100644
index 000000000000..65cb22d5f653
--- /dev/null
+++ b/dev-python/protobuf-python/files/protobuf-python-4.22.5-python.patch
@@ -0,0 +1,21 @@
+See also https://github.com/protocolbuffers/protobuf/pull/9098
+--- a/google/protobuf/internal/json_format_test.py
++++ b/google/protobuf/internal/json_format_test.py
+@@ -1060,7 +1060,7 @@ class JsonFormatTest(JsonFormatBase):
+   def testInvalidTimestamp(self):
+     message = json_format_proto3_pb2.TestTimestamp()
+     text = '{"value": "10000-01-01T00:00:00.00Z"}'
+-    self.assertRaisesRegexp(
++    self.assertRaisesRegex(
+         json_format.ParseError, 'Failed to parse value field: '
+         'time data \'10000-01-01T00:00:00\' does not match'
+         ' format \'%Y-%m-%dT%H:%M:%S\' at TestTimestamp.value.',
+@@ -1097,7 +1097,7 @@ class JsonFormatTest(JsonFormatBase):
+   def testInvalidOneof(self):
+     message = json_format_proto3_pb2.TestOneof()
+     text = '{"oneofInt32Value": 1, "oneofStringValue": "2"}'
+-    self.assertRaisesRegexp(
++    self.assertRaisesRegex(
+         json_format.ParseError, 'Message type "proto3.TestOneof"'
+         ' should not have multiple "oneof_value" oneof fields at "TestOneof".',
+         json_format.Parse, text, message)

diff --git a/dev-python/protobuf-python/protobuf-python-4.22.5.ebuild b/dev-python/protobuf-python/protobuf-python-4.22.5.ebuild
index 9cf2f3d4c74a..59b4f648ed71 100644
--- a/dev-python/protobuf-python/protobuf-python-4.22.5.ebuild
+++ b/dev-python/protobuf-python/protobuf-python-4.22.5.ebuild
@@ -56,6 +56,7 @@ PARENT_PATCHES=(
 
 # Here for patches within "python/" subdirectory.
 PATCHES=(
+	"${FILESDIR}/${PN}-4.22.5-python.patch"
 )
 
 python_prepare_all() {


             reply	other threads:[~2024-06-13  4:53 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-13  4:53 Sam James [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-01-05 11:12 [gentoo-commits] repo/gentoo:master commit in: dev-python/protobuf-python/, dev-python/protobuf-python/files/ Michał Górny
2022-10-26 22:35 Sam James
2022-10-25 23:02 Sam James
2021-11-09 11:51 Arthur Zamarin
2018-10-02 20:08 Mike Gilbert
2018-04-26 15:14 Mike Gilbert

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1718254380.de15b02f0b35c97ba57195624a582d191b038812.sam@gentoo \
    --to=sam@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox