public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Mamoru TASAKA <mtasaka@fedoraproject.org>
To: git-commits@fedoraproject.org
Subject: [rpms/rubygem-pg] rawhide: Apply upstream fix to support json 3
Date: Sun, 20 Sep 2026 06:34:12 GMT [thread overview]
Message-ID: <178988605285.1.15831298299134110254.rpms-rubygem-pg-5400f0b637e4@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/rubygem-pg
Branch : rawhide
Commit : 5400f0b637e485f9fda3f4ec175bbdd03780c6e1
Author : Mamoru TASAKA <mtasaka@fedoraproject.org>
Date : 2026-09-20T15:34:00+09:00
Stats : +52/-1 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/rubygem-pg/c/5400f0b637e485f9fda3f4ec175bbdd03780c6e1?branch=rawhide
Log:
Apply upstream fix to support json 3
---
diff --git a/rubygem-pg-pr737-support-json3.patch b/rubygem-pg-pr737-support-json3.patch
new file mode 100644
index 0000000..f3ce615
--- /dev/null
+++ b/rubygem-pg-pr737-support-json3.patch
@@ -0,0 +1,44 @@
+From ebb4f88a80807d8e5391aca95ef573cf0ba5cd96 Mon Sep 17 00:00:00 2001
+From: Lars Kanis <lars@greiz-reinsdorf.de>
+Date: Tue, 11 Aug 2026 21:08:41 +0200
+Subject: [PATCH] Remove option "quirks_mode" from JSON en/decoder
+
+The option was introduces as part of https://github.com/ged/ruby-pg/issues/248 .
+However the "quirks_mode" was removed short time later from json gem:
+ https://github.com/ruby/json/commit/7d2ad6d6556da03300a5aeadeeacaec563435773
+
+It was ignored since then, but recent ruby fails with:
+ `ArgumentError: unknown keyword: quirks_mode`
+at `JSON.parse` and `JSON.generate` since that commit:
+ https://github.com/ruby/ruby/commit/ac60d4ae4dc9aeb522d242406345e7f8834e76cd
+---
+ lib/pg/text_decoder/json.rb | 2 +-
+ lib/pg/text_encoder/json.rb | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/lib/pg/text_decoder/json.rb b/lib/pg/text_decoder/json.rb
+index 93ecd55d0..c5a4c118e 100644
+--- a/lib/pg/text_decoder/json.rb
++++ b/lib/pg/text_decoder/json.rb
+@@ -10,7 +10,7 @@ module TextDecoder
+ # As soon as this class is used, it requires the ruby standard library 'json'.
+ class JSON < SimpleDecoder
+ def decode(string, tuple=nil, field=nil)
+- ::JSON.parse(string, quirks_mode: true)
++ ::JSON.parse(string)
+ end
+ end
+ end
+diff --git a/lib/pg/text_encoder/json.rb b/lib/pg/text_encoder/json.rb
+index 36bbc704a..51e6a2cc9 100644
+--- a/lib/pg/text_encoder/json.rb
++++ b/lib/pg/text_encoder/json.rb
+@@ -10,7 +10,7 @@ module TextEncoder
+ # As soon as this class is used, it requires the ruby standard library 'json'.
+ class JSON < SimpleEncoder
+ def encode(value)
+- ::JSON.generate(value, quirks_mode: true)
++ ::JSON.generate(value)
+ end
+ end
+ end
diff --git a/rubygem-pg.spec b/rubygem-pg.spec
index 7841e38..4c6b3c1 100644
--- a/rubygem-pg.spec
+++ b/rubygem-pg.spec
@@ -3,7 +3,7 @@
Name: rubygem-%{gem_name}
Version: 1.6.3
-Release: 3%{?dist}
+Release: 4%{?dist}
Summary: Pg is the Ruby interface to the PostgreSQL RDBMS
License: (BSD-2-Clause OR Ruby) AND PostgreSQL
URL: https://github.com/ged/ruby-pg
@@ -14,6 +14,9 @@ Source1: %{gem_name}-%{version}-spec.tar.gz
# Disable RPATH.
# https://github.com/ged/ruby-pg/issues/183
Patch0: rubygem-pg-1.3.0-remove-rpath.patch
+# Support json 3
+# https://github.com/ged/ruby-pg/pull/737
+Patch1: rubygem-pg-pr737-support-json3.patch
# lib/pg/text_{de,en}coder.rb
Requires: rubygem(json)
# This is optional dependency now.
@@ -49,6 +52,7 @@ Documentation for %{name}.
%setup -q -n %{gem_name}-%{version} -b 1
%patch 0 -p1
+%patch 1 -p1
%build
# Create the gem as gem install only works on a gem file
@@ -119,6 +123,9 @@ popd
%{gem_instdir}/sample
%changelog
+* Sun Sep 13 2026 Mamoru TASAKA <mtasaka@fedoraproject.org> - 1.6.3-4
+- Apply upstream fix to support json 3
+
* Fri Jul 17 2026 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.3-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_45_Mass_Rebuild
reply other threads:[~2026-09-20 6:34 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=178988605285.1.15831298299134110254.rpms-rubygem-pg-5400f0b637e4@fedoraproject.org \
--to=mtasaka@fedoraproject.org \
--cc=git-commits@fedoraproject.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