Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Encoding is not available to Ruby scripts on 1.2 #433
Comments
flashcode
added
the
bug
label
Jun 4, 2015
evilgawd
commented
Jun 15, 2015
|
Same issue on Fedora 22 ruby --version weechat =!= | ruby: error while loading file "/home/blip/.weechat/ruby/autoload/pushover-weechat.rb" |
evilgawd
commented
Jun 23, 2015
|
Is there any workaround for this ? |
|
For now I have no workaround. |
akaritakai
commented
Jul 14, 2015
|
I also ran into this on 1.3 while using a gem that required uri. I don't have a workaround either. |
ChinnoDog
commented
Jul 14, 2015
|
I found this problem in 1.3 after doing a package upgrade on my Ubuntu server. I use slacklog.rb and encounter this error when I attempt to load it in weechat. I used irb to interactively load the script's object and it does not complain. The uri issue only appears in weechat. I only have one version of Ruby on my server and that is 2.0. |
|
Ruby developers/gurus: a patch is still welcome for this issue :) |
flashcode
added
the
help wanted
label
Jul 16, 2015
jferris
referenced this issue
in thoughtbot/weechat-slacklog
Jul 27, 2015
Closed
Error on loading #14
akerl
commented
Sep 5, 2015
|
So the encodings made available inside weechat differ dramatically from those on the system:
That script uses the following the generate that output:
Was there a code change recently that would have impacted the locales you present when loading Ruby? |
akerl
commented
Sep 5, 2015
|
Looks very related to https://savannah.nongnu.org/bugs/?41115 |
akerl
commented
Sep 5, 2015
|
My C skills are pretty horrible, but looking at d8b9e0a, it looks like you may be checking |
akerl
commented
Sep 5, 2015
|
No luck. Removing that had no visible impact |
akerl
commented
Sep 14, 2015
|
@flashcode Have you had a chance to look into this? It's pretty crippling given that ever since upgrading to latest weechat, ruby scripts are all dead in the water |
|
@akerl: I played with the include of encoding.h, but no luck, I think the problem is not there. The problem could be in |
jkolo
commented
Oct 4, 2015
|
For me workaround/solution is to add to script (.weechat/ruby/<name_of_script>.rb) line |
gsingh93
commented
Oct 25, 2015
|
@jkolo's workaround works for me. Hopefully this gets a proper solution sometime soon. |
|
Yes it works with this workaround, but I'm not able to apply this workaround on the script loader (in weechat-ruby.c). |
|
Ah, good news, just found a way to fix the problem by moving the include of |
flashcode
closed this
in
4f867a8
Oct 27, 2015
flashcode
removed
the
help wanted
label
Oct 27, 2015
flashcode
added this to the 1.4 milestone
Oct 27, 2015
flashcode
self-assigned this
Oct 27, 2015
|
Please try with the latest commit, it should fix the problem. |
The-Compiler
commented
Dec 8, 2015
|
Gosh, I didn't update in ages... on the bright side, I can confirm the fix works |
jferris commentedJun 3, 2015
You can reproduce this with the following Ruby script:
I get the following error:
I'm on Ruby 2.2.2, Weechat 1.2, Arch Linux: