bp_test FAIL:163

58 views
Skip to first unread message

ipso Facto

unread,
Nov 21, 2013, 6:10:15 PM11/21/13
to biop...@googlegroups.com
Ubuntu 10.04 server
ruby 1.9.1
biopieces - All dependencies installed, except vmatch.

When I run bp_test, I get 163 failures.
If I try to re-run the tests individually, I get the same error for all the tests.
   biopieces.rb:154:in `<class:Biopieces>': undefined method `each_entry' for class `Biopieces' (NameError)

I list three of them below:

$ kmer_freq -I $BP_DIR/bp_test/in/kmer_freq.in -O $BP_TMP/bdhillon.kmer_freq.out
/biopieces/code_ruby/lib/maasha/biopieces.rb:154:in `<class:Biopieces>': undefined method `each_entry' for class `Biopieces' (NameError)
    from /biopieces/code_ruby/lib/maasha/biopieces.rb:67:in `<top (required)>'
    from /biopieces/bp_bin/kmer_freq:31:in `require'
    from /biopieces/bp_bin/kmer_freq:31:in `<main>'


$ read_fastq -i $BP_DIR/bp_test/in/read_fastq.in.3 -j $BP_DIR/bp_test/in/read_fastq.in.4 -O $BP_TMP/bdhillon.read_fastq.out
/biopieces/code_ruby/lib/maasha/biopieces.rb:154:in `<class:Biopieces>': undefined method `each_entry' for class `Biopieces' (NameError)
    from /biopieces/code_ruby/lib/maasha/biopieces.rb:67:in `<top (required)>'
    from /biopieces/bp_bin/read_fastq:31:in `require'
    from /biopieces/bp_bin/read_fastq:31:in `<main>'


$ write_tab -I $BP_DIR/bp_test/in/write_tab.in -d ',' -o $BP_TMP/bdhillon.write_tab.out -x
/biopieces/code_ruby/lib/maasha/biopieces.rb:154:in `<class:Biopieces>': undefined method `each_entry' for class `Biopieces' (NameError)
    from /biopieces/code_ruby/lib/maasha/biopieces.rb:67:in `<top (required)>'
    from /biopieces/bp_bin/write_tab:38:in `require'
    from /biopieces/bp_bin/write_tab:38:in `<main>'

Martin Asser Hansen

unread,
Nov 22, 2013, 4:48:34 AM11/22/13
to biop...@googlegroups.com
It looks like there is a problem with your environment. Did you run `source ~/.bashrc` after the installation or do a re-login?

What does your ~/.bashrc file say?

What does `env | grep BP` say?

And `which ruby`?


Cheers,


Martin


--
You received this message because you are subscribed to the Google Groups "biopieces" group.
To unsubscribe from this group and stop receiving emails from it, send an email to biopieces+...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

ipso Facto

unread,
Nov 22, 2013, 1:23:42 PM11/22/13
to biop...@googlegroups.com, ma...@maasha.dk
Hi Martin,
Thanks.
I did do source ~/.bashrc.
Below is the output of the commands you listed. To me it looks like everything is in place, but I may be missing something.

$ cat ~/.bashrc | grep BP
export BP_DIR="$HOME/biopieces"  # Directory where biopieces are installed
export BP_DATA="$HOME/BP_DATA"   # Contains genomic data etc.
export BP_TMP="$HOME/tmp"        # Required temporary directory.
export BP_LOG="$HOME/BP_LOG"     # Required log directory.
if [ -f "$BP_DIR/bp_conf/bashrc" ]; then
    source "$BP_DIR/bp_conf/bashrc"


$ env | grep BP
BP_PERL=$HOME/biopieces/code_perl
BP_PYTHON=$HOME/biopieces/code_python
BP_BIN=$HOME/biopieces/bp_bin
BP_WWW=$HOME/biopieces/www
BP_DATA=$HOME/BP_DATA
BP_TMP=$HOME/tmp
BP_LOG=$HOME/BP_LOG
BP_DIR=$HOME/biopieces
BP_C=$HOME/biopieces/code_c
BP_RUBY=$HOME/biopieces/code_ruby


$ which ruby
/usr/bin/ruby

Martin Asser Hansen

unread,
Nov 22, 2013, 1:36:48 PM11/22/13
to biop...@googlegroups.com
Hrm, yes that looks sane.

I have on my mac:

maasha@mel:~$ grep BP .bashrc
export BP_DIR="$HOME/biopieces"  # Directory where biopieces are installed
export BP_DATA="$HOME/BP_DATA"   # Contains genomic data etc.
export BP_TMP="$HOME/BP_TMP"     # Required temporary directory.
export BP_LOG="$HOME/BP_LOG"     # Required log directory.
if [ -f "$BP_DIR/bp_conf/bashrc" ]; then
    source "$BP_DIR/bp_conf/bashrc"

and

maasha@mel:~$ env | grep BP
BP_PERL=/Users/maasha/biopieces/code_perl
BP_PYTHON=/Users/maasha/biopieces/code_python
BP_BIN=/Users/maasha/biopieces/bp_bin
BP_WWW=/Users/maasha/biopieces/www
BP_DATA=/Users/maasha/BP_DATA
BP_TMP=/Users/maasha/BP_TMP
BP_LOG=/Users/maasha/BP_LOG
BP_DIR=/Users/maasha/biopieces
BP_C=/Users/maasha/biopieces/code_c
BP_RUBY=/Users/maasha/biopieces/code_ruby

and because I compiled my own ruby:

maasha@mel:~$ which ruby
/Users/maasha/Install/bin/ruby
maasha@mel:~$ ruby --version
ruby 2.0.0p247 (2013-06-27 revision 41674) [x86_64-darwin11.4.2]

But yours should be just fine.

Now, the offending line is:

alias :get_record :each_entry

Which is totally trivial and I never experienced problems with...

I can only suggest that you try compile your own version or Ruby - and perhaps version 2.0.


Cheers,


Martin

ipso Facto

unread,
Nov 22, 2013, 1:56:10 PM11/22/13
to biop...@googlegroups.com, ma...@maasha.dk
Thanks for the suggestion Martin.
I will try to upgrade Ruby and see if the error goes away.

ipso Facto

unread,
Nov 24, 2013, 11:35:56 PM11/24/13
to biop...@googlegroups.com, ma...@maasha.dk
Thanks again Martin,

I updated from ruby1.9.1 to ruby 2.0.0p353 (2013-11-22 revision 43784) [x86_64-linux],
and bp_test looks great.
Biopieces tested: 83  Tests run: 275  OK: 273  FAIL: 2  WARNING: 0  Time: 44 secs

It works.
Thanks.
Reply all
Reply to author
Forward
0 new messages