Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 532120 - kde-base/qtruby-4.14.3-r1 doesn't work correctly with ruby 2.0
Summary: kde-base/qtruby-4.14.3-r1 doesn't work correctly with ruby 2.0
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] KDE (show other bugs)
Hardware: All Linux
: Normal major (vote)
Assignee: Gentoo KDE team
URL: https://bugs.kde.org/show_bug.cgi?id=...
Whiteboard:
Keywords: PATCH
Depends on:
Blocks: kde-4.14.3-stable
  Show dependency tree
 
Reported: 2014-12-10 09:44 UTC by Stefano Crocco
Modified: 2015-01-18 20:55 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
simple ruby script showing the effects of this bug (test_qtruby_ruby2_signals.rb,292 bytes, text/plain)
2014-12-10 09:44 UTC, Stefano Crocco
Details
patch to fix this bug (ruby2_signals.patch,646 bytes, patch)
2014-12-10 09:46 UTC, Stefano Crocco
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Stefano Crocco 2014-12-10 09:44:20 UTC
Created attachment 391348 [details]
simple ruby script showing the effects of this bug

qtruby-4.14.3-r1 uses ruby 2.0, but according to KDE bug 330800, it doesn't work correctly because signals defined in ruby programs aren't emitted. Since defining signals in ruby is quite common, this bug makes qtruby unusable with ruby 2. The bug report also includes a patch which should make qtruby work with ruby 2.

I attach a simple ruby file which shows this behaviour. When run using qtruby-4.14.3 and ruby 1.9.3, it prints the text "SIGNAL RECEIVED". When run using qtruby-4.14.3-r1 with ruby 2.0, it prints nothing. When applying the patch mentioned in the KDE bug report, it works correctly again.

Note that, while the patch works for this simple script, I've not tested it in real programs so, while it should fix this problem, I'm not sure whether it has other, unintended consequences.
Comment 1 Stefano Crocco 2014-12-10 09:46:35 UTC
Created attachment 391350 [details, diff]
patch to fix this bug

This is the patch suggested in the KDE bug report to fix this bug
Comment 2 Johannes Huber (RETIRED) gentoo-dev 2015-01-18 20:55:57 UTC
Thanks for reporting. This is fixed in cvs now please sync in some hours to get the changes.

+
+  18 Jan 2015; Johannes Huber <johu@gentoo.org>
+  +files/qtruby-4.14.3-ruby20.patch, +qtruby-4.14.3-r2.ebuild,
+  qtruby-4.14.3.ebuild:
+  Revision bump adds patch to fix signals in ruby20 spotted by Stefano Crocco
+  <stefano.crocco@alice.it>, bug #532120.
+