[DRE-maint] Bug#1087952: ruby-dataobjects: fix FTBFS with Ruby 3.2+

Zixing Liu zixing.liu at canonical.com
Wed Nov 20 19:40:55 GMT 2024


Package: ruby-dataobjects
Version: 0.10.17-2
Severity: normal
Tags: patch ftbfs
User: ubuntu-devel at lists.ubuntu.com
Usertags: origin-ubuntu plucky ubuntu-patch

Dear Maintainer,

In Ubuntu, the attached patch was applied to achieve the following:

  * d/p/0070-fix-compat-with-ruby-3.patch: add a patch to fix the compatibility
    issues with Ruby 3.x (LP: #2083851).


Thanks for considering the patch.


-- System Information:
Debian Release: trixie/sid
  APT prefers oracular-updates
  APT policy: (500, 'oracular-updates'), (500, 'oracular-security'), (500, 'oracular')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 6.11.0-9-generic (SMP w/10 CPU threads; PREEMPT)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_WARN, TAINT_OOT_MODULE
Locale: LANG=en_CA.UTF-8, LC_CTYPE=en_CA.UTF-8 (charmap=UTF-8), LANGUAGE=en_CA:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
-------------- next part --------------
diff -Nru ruby-dataobjects-0.10.17/debian/patches/0070-fix-compat-with-ruby-3.patch ruby-dataobjects-0.10.17/debian/patches/0070-fix-compat-with-ruby-3.patch
--- ruby-dataobjects-0.10.17/debian/patches/0070-fix-compat-with-ruby-3.patch	1969-12-31 17:00:00.000000000 -0700
+++ ruby-dataobjects-0.10.17/debian/patches/0070-fix-compat-with-ruby-3.patch	2024-10-07 10:33:44.000000000 -0600
@@ -0,0 +1,21 @@
+Description: Fix Ruby 3.x compatibility
+ In Ruby 3.3, numeric types are merged. Instead of having Fixnum and BigInt,
+ these become Integer type in Ruby 3.3.
+Author: Zixing Liu <zixing.liu at canonical.com>
+Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/ruby-dataobjects/+bug/2083851
+Forwarded: not-needed
+Last-Update: 2024-10-07
+---
+Index: ruby-dataobjects/lib/data_objects/pooling.rb
+===================================================================
+--- ruby-dataobjects.orig/lib/data_objects/pooling.rb
++++ ruby-dataobjects/lib/data_objects/pooling.rb
+@@ -146,7 +146,7 @@ module DataObjects
+       attr_reader :used
+ 
+       def initialize(max_size, resource, args)
+-        raise ArgumentError.new("+max_size+ should be a Fixnum but was #{max_size.inspect}") unless Fixnum === max_size
++        raise ArgumentError.new("+max_size+ should be a Integer but was #{max_size.inspect}") unless Integer === max_size
+         raise ArgumentError.new("+resource+ should be a Class but was #{resource.inspect}") unless Class === resource
+ 
+         @max_size = max_size
diff -Nru ruby-dataobjects-0.10.17/debian/patches/series ruby-dataobjects-0.10.17/debian/patches/series
--- ruby-dataobjects-0.10.17/debian/patches/series	2020-02-04 10:03:23.000000000 -0700
+++ ruby-dataobjects-0.10.17/debian/patches/series	2024-10-07 10:33:44.000000000 -0600
@@ -3,3 +3,4 @@
 0050-tests-support-rspec3.patch
 0060-lib-spec-support-rspec3.patch
 0005-Do-not-call-new-method-for-BigDecimal.patch
+0070-fix-compat-with-ruby-3.patch


More information about the Pkg-ruby-extras-maintainers mailing list