Can someone in Japan please kancho the authors of the bioruby gem at Kyoto University?

With every method call, the bioruby gem is surprising me with its
behavior–not pleasant surprises either (more like an unpleasant
kancho kind of surprise–hence the request to repay the authors).

For those who haven’t been to Japan and are wondering what a kancho
is:
http://www.kancho.org/how_to_kancho.html

First, it has rather strange behavior when it comes to opening files.
For instance, when I try to open a genbank file like so:

require ‘bio’
=>true

f = Bio::GenBank.open(“Ago2.seq”)
=> #<Bio::FlatFile:0x11fa724 @raw=false, @firsttime_flag=true,
@splitter=#<Bio::FlatFile::Splitter::Default:0x11fa558
@delimiter_overrun=nil, @entry_pos_flag=nil,
@stream=#<Bio::FlatFile::BufferedInputStream:0x11fa6d4
@path=“Ago2.seq”, @io=#<File:Ago2.seq>, @buffer="">, @header=“LOCUS “,
@delimiter=”\n//\n”>, @stream=#<Bio::FlatFile::BufferedInputStream:
0x11fa6d4 @path=“Ago2.seq”, @io=#<File:Ago2.seq>, @buffer="">,
@skip_leader_mode=:firsttime, @dbclass=Bio::GenBank>

#Surprise!!! I asked for a GenBank object and got a FlatFile object
back.
#Principle of least surprise would be Bio::GenBank.open =>
Bio::GenBank

f.instance_variables
=> ["@raw", “@firsttime_flag”, “@splitter”, “@stream”,
@skip_leader_mode”, “@dbclass”]

#looking for my object by iterating through the gratuitous FlatFile
object.

f.each{|x| puts x}
#Bio::GenBank:0x11f6e94
=> nil

f.instance_variables
=> ["@raw", “@firsttime_flag”, “@splitter”, “@stream”,
@skip_leader_mode”, “@dbclass”, “@entry”]

#Surprise!!! calling each on an object altered the object, by adding
an instance variable. #What?!!?! I have never seen a case where
calling each altered the object.

Kancho! Kancho! Kancho!
Tim

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs