Package: release.debian.org
Severity: normal
Tags: bullseye
User: release.debian....@packages.debian.org
Usertags: pu
This rc bug was detected very late in freeze so it could not get into
bullseye.
[ Reason ]
This package was broken with ruby-rqrcode 1.0 update. See #992040
[ Impact ]
They will have an incompatible and broken package.
[ Tests ]
This was found when testing 2FA authentication in gitlab package and
the fix was tested in gitlab and the 2FA feature was working in the
fixed versions.
[ Risks ]
gitlab is its only reverse dependency which is not in bullseye.
[ Checklist ]
[x] *all* changes are documented in the d/changelog
[x] I reviewed all changes and I approve them
[x] attach debdiff against the package in (old)stable
[x] the issue is verified as fixed in unstable
[ Changes ]
API is adjusted to work with ruby-rqrcode shipped with bullseye.
[ Other info ]
The patch was taken from an upstream issue (though upstream is not very
active)
diff -Nru ruby-rqrcode-rails3-0.1.7/debian/changelog ruby-rqrcode-rails3-0.1.7/debian/changelog
--- ruby-rqrcode-rails3-0.1.7/debian/changelog 2021-01-05 20:52:02.000000000 +0530
+++ ruby-rqrcode-rails3-0.1.7/debian/changelog 2021-08-16 00:40:15.000000000 +0530
@@ -1,3 +1,10 @@
+ruby-rqrcode-rails3 (0.1.7-1.1+deb11u1) bullseye; urgency=medium
+
+ * Fix for ruby-rqrcode 1.0 compatibility (Thanks to Florence Foo)
+ (Closes: #992040)
+
+ -- Pirate Praveen <prav...@debian.org> Mon, 16 Aug 2021 00:40:15 +0530
+
ruby-rqrcode-rails3 (0.1.7-1.1) unstable; urgency=medium
* Non maintainer upload by the Reproducible Builds team.
diff -Nru ruby-rqrcode-rails3-0.1.7/debian/patches/rqrcode-1.x-compat.patch ruby-rqrcode-rails3-0.1.7/debian/patches/rqrcode-1.x-compat.patch
--- ruby-rqrcode-rails3-0.1.7/debian/patches/rqrcode-1.x-compat.patch 1970-01-01 05:30:00.000000000 +0530
+++ ruby-rqrcode-rails3-0.1.7/debian/patches/rqrcode-1.x-compat.patch 2021-08-16 00:20:04.000000000 +0530
@@ -0,0 +1,36 @@
+https://github.com/samvincent/rqrcode-rails3/compare/master...pandamouse:rqrcode-core-0.1.1.patch
+
+From bc86ea646010ab0e6d089d80f1533b7836315776 Mon Sep 17 00:00:00 2001
+From: Florence Foo <flore...@kwelasolutions.com>
+Date: Thu, 2 Jan 2020 17:07:55 +1100
+Subject: [PATCH 1/2] RQRCode.render_qrcode raises NoMethodError #21
+
+- use RQRCodeCore
+ - is_dark? -> dark?
+---
+ lib/rqrcode-rails3.rb | 2 +-
+ lib/rqrcode-rails3/renderers/svg.rb | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+--- a/lib/rqrcode-rails3.rb
++++ b/lib/rqrcode-rails3.rb
+@@ -15,7 +15,7 @@
+ size = options[:size] || RQRCode.minimum_qr_size_from_string(string)
+ level = options[:level] || :h
+
+- qrcode = RQRCode::QRCode.new(string, :size => size, :level => level)
++ qrcode = RQRCodeCore::QRCode.new(string, :size => size, :level => level)
+ svg = RQRCode::Renderers::SVG::render(qrcode, options)
+
+ if format && format == :svg
+--- a/lib/rqrcode-rails3/renderers/svg.rb
++++ b/lib/rqrcode-rails3/renderers/svg.rb
+@@ -28,7 +28,7 @@
+ y = c*unit + offset
+ x = r*unit + offset
+
+- next unless qrcode.is_dark(c, r)
++ next unless qrcode.checked?(c, r)
+ tmp << %{<rect width="#{unit}" height="#{unit}" x="#{x}" y="#{y}" style="fill:##{color}"/>}
+ end
+ result << tmp.join
diff -Nru ruby-rqrcode-rails3-0.1.7/debian/patches/series ruby-rqrcode-rails3-0.1.7/debian/patches/series
--- ruby-rqrcode-rails3-0.1.7/debian/patches/series 1970-01-01 05:30:00.000000000 +0530
+++ ruby-rqrcode-rails3-0.1.7/debian/patches/series 2021-08-16 00:20:04.000000000 +0530
@@ -0,0 +1 @@
+rqrcode-1.x-compat.patch