Inconsistent testing Ruby 1.8.4 on Tiger.

S

sean.swolfe

I was able to build ruby 1.8.4 on my Tiger (OSX 10.4.3) box here.
Everything built fine, and it appears that the readline support works
as well. But when i run "make test-all" I get Inconsistent results.
Ocne I'd get the following failures:

1) Failure:
test_cgi(TestWEBrickCGI)
[./webrick/test_cgi.rb:27:in `test_cgi'
/Users/seanwolfe/src/ruby-1.8.4/lib/net/http.rb:1049:in `request'
/Users/seanwolfe/src/ruby-1.8.4/lib/net/http.rb:2104:in
`reading_body'
/Users/seanwolfe/src/ruby-1.8.4/lib/net/http.rb:1048:in `request'
/Users/seanwolfe/src/ruby-1.8.4/lib/net/http.rb:1033:in `request'
/Users/seanwolfe/src/ruby-1.8.4/lib/net/http.rb:545:in `start'
/Users/seanwolfe/src/ruby-1.8.4/lib/net/http.rb:1031:in `request'
./webrick/test_cgi.rb:27:in `test_cgi'
./webrick/utils.rb:26:in `start_server'
./webrick/utils.rb:34:in `start_httpserver'
./webrick/test_cgi.rb:24:in `test_cgi']:
<"/webrick.cgi"> expected but was
<"<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\">\n<HTML>\n
<HEAD><TITLE>Internal Server Error</TITLE></HEAD>\n <BODY>\n
<H1>Internal Server Error</H1>\n Premature end of script headers:
/Users/seanwolfe/src/ruby-1.8.4/test/webrick/webrick.cgi\n <HR>\n
<ADDRESS>\n WEBrick/1.3.1 (Ruby/1.8.4/2005-12-24) OpenSSL/0.9.7b
at\n 127.0.0.1:59698\n </ADDRESS>\n </BODY>\n</HTML>\n">.

2) Failure:
test_nil_parse(Test_Features)
[./xmlrpc/test_features.rb:43:in `test_nil_parse'
/Users/seanwolfe/src/ruby-1.8.4/lib/xmlrpc/parser.rb:803:in
`each_installed_parser'
/Users/seanwolfe/src/ruby-1.8.4/lib/xmlrpc/parser.rb:801:in
`each_installed_parser'
./xmlrpc/test_features.rb:33:in `test_nil_parse'
/Users/seanwolfe/src/ruby-1.8.4/lib/xmlrpc/create.rb:95:in
`each_installed_writer'
/Users/seanwolfe/src/ruby-1.8.4/lib/xmlrpc/create.rb:93:in
`each_installed_writer'
./xmlrpc/test_features.rb:30:in `test_nil_parse']:
<[nil, {"test"=>nil}, [nil, nil]]> expected but was
<[nil, {"test"=>nil}, [nil, 1, nil]]>.

With another run, I'd get:
/Users/seanwolfe/src/ruby-1.8.4/lib/rational.rb:453: [BUG]
Segmentation fault

I've also seen the last error before, but on different files.

All other tests seem to pass. IS this any call for alarm? If there is
something wrong, I don't want to overwrite my current working ruby
1.8.2 install. I also never liked installing packages with fink or
DarwinPorts, always seem to muck things up. Does anyone have a
successful test run of 1.84 from building on tiger?

Sean
 
S

sean.swolfe

Christian said:
I noticed that too (late), doing "make install" before testing makes it go
away, probably a path issue of the ruby interpreter.

Hmmm... So this may have something to do with the already installed
copy of Ruby that is in my /usr/bin path? I've tried a few more builds.
Let me list the results:

(just a note, the last build and these first few builds had the CFLAGS
environment variable set to "-mcpu=G5 -mtune=G5 -O3")
First new run:
$ sudo gcc_select 3.3
$ ./configure --prefix=/usr
$ make
$ make test-all
results:

../miniruby ./runruby.rb --extout=.ext -- -C "./test" runner.rb
--runner=console
Loaded suite .
Started
<snip>
Finished in 157.68762 seconds.

1) Failure:
test_cgi(TestWEBrickCGI)
[./webrick/test_cgi.rb:27:in `test_cgi'
/usr/src/ruby/ruby-1.8.4/lib/net/http.rb:1049:in `request'
/usr/src/ruby/ruby-1.8.4/lib/net/http.rb:2104:in `reading_body'
/usr/src/ruby/ruby-1.8.4/lib/net/http.rb:1048:in `request'
/usr/src/ruby/ruby-1.8.4/lib/net/http.rb:1033:in `request'
/usr/src/ruby/ruby-1.8.4/lib/net/http.rb:545:in `start'
/usr/src/ruby/ruby-1.8.4/lib/net/http.rb:1031:in `request'
./webrick/test_cgi.rb:27:in `test_cgi'
./webrick/utils.rb:26:in `start_server'
./webrick/utils.rb:34:in `start_httpserver'
./webrick/test_cgi.rb:24:in `test_cgi']:
<"/webrick.cgi"> expected but was
<"<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\">\n<HTML>\n
<HEAD><TITLE>Internal Server Error</TITLE></HEAD>\n <BODY>\n
<H1>Internal Server Error</H1>\n Premature end of script headers:
/usr/src/ruby/ruby-1.8.4/test/webrick/webrick.cgi\n <HR>\n
<ADDRESS>\n WEBrick/1.3.1 (Ruby/1.8.4/2005-12-24) OpenSSL/0.9.7b
at\n 127.0.0.1:64887\n </ADDRESS>\n </BODY>\n</HTML>\n">.

1313 tests, 14436 assertions, 1 failures, 0 errors
make: *** [test-all] Error 1

second run:
$ ./miniruby ./runruby.rb --extout=.ext -- -C "./test" runner.rb
--runner=console
results:
<same error as last result>

third run:
$ sudo gcc_select 4.0
$ make clean
$ ./configure --prefix=/usr
$ make
$ make test-all
results:
<same error as the first result>

fourth run:
$ gdb make
(gdb) run test-all
results:
Starting program: /usr/bin/make test-all
Reading symbols for shared libraries . done
../miniruby ./runruby.rb --extout=.ext -- -C "./test" runner.rb
--runner=console
Loaded suite .
Started
...................................................................................................................................................................................................................................................................................................................................................................................................................................................................../usr/src/ruby/ruby-1.8.4/lib/rinda/tuplespace.rb:173:
[BUG] Segmentation fault
ruby 1.8.4 (2005-12-24) [powerpc-darwin8.3.0]

make: *** [test-all] Abort trap

Program exited with code 02.
(gdb) bt
No stack.

fifth run:
(I see that I couldn't get a backtrace so I'll try to run it outside of
make.)
I'm cutting the commands and results short since the debugger caught a
lot of SIGPIPE signals.
here is one result i received, with a backtrace:

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0xc24bc195
0x0000d608 in rb_eval ()
(gdb) bt
#0 0x0000d608 in rb_eval ()
#1 0x0000d658 in rb_eval ()
warning: Previous frame identical to this frame (corrupt stack?)
#2 0x0000bc1c in rb_eval ()
#3 0x0001104c in rb_call0 ()
#4 0x00011874 in rb_call ()
#5 0x0000d834 in rb_eval ()
#6 0x0000e710 in rb_eval ()
#7 0x0000c520 in rb_eval ()
#8 0x0001104c in rb_call0 ()
#9 0x00011874 in rb_call ()
#10 0x0000d834 in rb_eval ()
#11 0x0001104c in rb_call0 ()
#12 0x00011874 in rb_call ()
#13 0x0000d834 in rb_eval ()
#14 0x0000ce14 in rb_eval ()
#15 0x0001104c in rb_call0 ()
#16 0x00011874 in rb_call ()
#17 0x0000db30 in rb_eval ()
#18 0x0001104c in rb_call0 ()
#19 0x00011874 in rb_call ()
#20 0x00012440 in rb_f_send ()
#21 0x00010a80 in rb_call0 ()
#22 0x00011874 in rb_call ()
#23 0x0000d834 in rb_eval ()
#24 0x0001f238 in block_pass ()
#25 0x0000c6cc in rb_eval ()
#26 0x0000ce14 in rb_eval ()
#27 0x0001104c in rb_call0 ()
#28 0x00011874 in rb_call ()
#29 0x0000d834 in rb_eval ()
#30 0x0001104c in rb_call0 ()
#31 0x00011874 in rb_call ()
#32 0x0000d834 in rb_eval ()
#33 0x0000e9dc in rb_eval ()
#34 0x0001104c in rb_call0 ()
#35 0x00011874 in rb_call ()
#36 0x0000db30 in rb_eval ()
#37 0x0000ce14 in rb_eval ()
#38 0x0000cfcc in rb_eval ()
#39 0x0001104c in rb_call0 ()
#40 0x00011874 in rb_call ()
#41 0x0000d834 in rb_eval ()
#42 0x0001f238 in block_pass ()
#43 0x0000c6cc in rb_eval ()
#44 0x000188a0 in rb_yield_0 ()
#45 0x000322e4 in rb_ary_each ()
#46 0x00010a80 in rb_call0 ()
#47 0x00011874 in rb_call ()
#48 0x0000d834 in rb_eval ()
#49 0x0000c894 in rb_eval ()
#50 0x0001104c in rb_call0 ()
#51 0x00011874 in rb_call ()
#52 0x0000d834 in rb_eval ()
#53 0x0001f238 in block_pass ()
#54 0x0000c6cc in rb_eval ()
#55 0x000188a0 in rb_yield_0 ()
#56 0x000322e4 in rb_ary_each ()
#57 0x00010a80 in rb_call0 ()
#58 0x00011874 in rb_call ()
#59 0x0000d834 in rb_eval ()
#60 0x0000c894 in rb_eval ()
#61 0x0001104c in rb_call0 ()
#62 0x00011874 in rb_call ()
#63 0x0000d834 in rb_eval ()
#64 0x0001f238 in block_pass ()
#65 0x0000c6cc in rb_eval ()
#66 0x000188a0 in rb_yield_0 ()
#67 0x000322e4 in rb_ary_each ()
#68 0x00010a80 in rb_call0 ()
#69 0x00011874 in rb_call ()
#70 0x0000d834 in rb_eval ()
#71 0x0000c894 in rb_eval ()
#72 0x0001104c in rb_call0 ()
#73 0x00011874 in rb_call ()
#74 0x0000d834 in rb_eval ()
#75 0x0000c894 in rb_eval ()
#76 0x0001104c in rb_call0 ()
#77 0x00011874 in rb_call ()
#78 0x0000d834 in rb_eval ()
#79 0x0000d2e0 in rb_eval ()
#80 0x0001104c in rb_call0 ()
#81 0x00011874 in rb_call ()
#82 0x0000db30 in rb_eval ()
#83 0x0000d2e0 in rb_eval ()
#84 0x0001104c in rb_call0 ()
#85 0x00011874 in rb_call ()
#86 0x0000d834 in rb_eval ()
#87 0x0000d2e0 in rb_eval ()
#88 0x0001104c in rb_call0 ()
#89 0x00011874 in rb_call ()
#90 0x0000d834 in rb_eval ()
#91 0x0000d658 in rb_eval ()
#92 0x0001104c in rb_call0 ()
#93 0x00011874 in rb_call ()
#94 0x0000d834 in rb_eval ()
#95 0x0001104c in rb_call0 ()
#96 0x00011874 in rb_call ()
#97 0x0000d834 in rb_eval ()
#98 0x0000d900 in rb_eval ()
#99 0x000225c8 in ruby_exec_internal ()
#100 0x00022680 in ruby_run ()
#101 0x00002090 in main ()


Could these segmentation faults be due to the optimization flags I used
when building Ruby? I'll try without the flags and try installing and
then testing to see how it runs.

sean
 
S

sean.swolfe

Hmmm.. Wierd, I just built 1.8.4 without the CFLAGS using GCC 4.0, and
then installed it. I tested it a bunch, the first 2 times had failures,
but on all the following runs, they all pass.

Here were the previous 2 failures.

1) Error:
test_doc_enc_doc_enc(SOAP::TestStyleUse):
SOAP::EncodingStyle::Handler::EncodingStyleError: illegal parent:

/usr/src/ruby/ruby-1.8.4/lib/soap/encodingstyle/soapHandler.rb:238:in
`decode_parent'

/usr/src/ruby/ruby-1.8.4/lib/soap/encodingstyle/soapHandler.rb:118:in
`as_struct'

/usr/src/ruby/ruby-1.8.4/lib/soap/encodingstyle/soapHandler.rb:219:in
`decode_parent'

/usr/src/ruby/ruby-1.8.4/lib/soap/encodingstyle/soapHandler.rb:177:in
`decode_tag'
/usr/src/ruby/ruby-1.8.4/lib/soap/parser.rb:179:in `decode_tag'
/usr/src/ruby/ruby-1.8.4/lib/soap/parser.rb:130:in `start_element'
/usr/src/ruby/ruby-1.8.4/lib/xsd/xmlparser/parser.rb:67:in
`start_element'
/usr/src/ruby/ruby-1.8.4/lib/xsd/xmlparser/rexmlparser.rb:34:in
`tag_start'
/usr/src/ruby/ruby-1.8.4/lib/rexml/parsers/streamparser.rb:24:in
`parse'
/usr/src/ruby/ruby-1.8.4/lib/rexml/document.rb:173:in
`parse_stream'
/usr/src/ruby/ruby-1.8.4/lib/xsd/xmlparser/rexmlparser.rb:27:in
`do_parse'
/usr/src/ruby/ruby-1.8.4/lib/soap/parser.rb:92:in `parse'
/usr/src/ruby/ruby-1.8.4/lib/soap/processor.rb:39:in `unmarshal'
/usr/src/ruby/ruby-1.8.4/lib/soap/rpc/router.rb:288:in `unmarshal'
/usr/src/ruby/ruby-1.8.4/lib/soap/rpc/router.rb:155:in `route'
/usr/src/ruby/ruby-1.8.4/lib/soap/rpc/soaplet.rb:88:in `do_POST'
/usr/src/ruby/ruby-1.8.4/lib/webrick/httpservlet/abstract.rb:35:in
`service'
/usr/src/ruby/ruby-1.8.4/lib/webrick/httpserver.rb:104:in `service'
/usr/src/ruby/ruby-1.8.4/lib/webrick/httpserver.rb:65:in `run'
/usr/src/ruby/ruby-1.8.4/lib/webrick/server.rb:173:in
`start_thread'
/usr/src/ruby/ruby-1.8.4/lib/webrick/server.rb:162:in
`start_thread'
/usr/src/ruby/ruby-1.8.4/lib/webrick/server.rb:95:in `start'
/usr/src/ruby/ruby-1.8.4/lib/webrick/server.rb:92:in `start'
/usr/src/ruby/ruby-1.8.4/lib/webrick/server.rb:23:in `start'
/usr/src/ruby/ruby-1.8.4/lib/webrick/server.rb:82:in `start'
/usr/src/ruby/ruby-1.8.4/lib/soap/rpc/httpserver.rb:123:in `run'
/usr/src/ruby/ruby-1.8.4/lib/logger.rb:668:in `start'
./soap/test_styleuse.rb:250:in `start_server_thread'
./soap/test_styleuse.rb:248:in `start_server_thread'
./soap/test_styleuse.rb:216:in `setup_server'
./soap/test_styleuse.rb:204:in `setup'
runner.rb:7
/usr/src/ruby/ruby-1.8.4/lib/soap/rpc/proxy.rb:354:in `raise_fault'
/usr/src/ruby/ruby-1.8.4/lib/soap/rpc/proxy.rb:147:in `call'
/usr/src/ruby/ruby-1.8.4/lib/soap/rpc/driver.rb:178:in `call'
/usr/src/ruby/ruby-1.8.4/lib/soap/rpc/driver.rb:232:in
`rpc_enc_rpc_enc'
./soap/test_styleuse.rb:299:in `test_doc_enc_doc_enc'

1) Error:
test_parser(RSS::TestSyndication):
NoMethodError: undefined method `include?' for -517611318:Fixnum
/usr/src/ruby/ruby-1.8.4/lib/rss/parser.rb:324:in
`start_else_element'
/usr/src/ruby/ruby-1.8.4/lib/rss/parser.rb:290:in `tag_start'
/usr/src/ruby/ruby-1.8.4/lib/rexml/parsers/streamparser.rb:24:in
`parse'
/usr/src/ruby/ruby-1.8.4/lib/rexml/document.rb:173:in
`parse_stream'
/usr/src/ruby/ruby-1.8.4/lib/rss/rexmlparser.rb:21:in `_parse'
/usr/src/ruby/ruby-1.8.4/lib/rss/parser.rb:143:in `parse'
/usr/src/ruby/ruby-1.8.4/lib/rss/parser.rb:70:in `parse'
./rss/test_syndication.rb:51:in `test_parser'
/usr/src/ruby/ruby-1.8.4/test/rss/rss-assertions.rb:53:in
`assert_too_much_tag'
/usr/src/ruby/ruby-1.8.4/test/rss/rss-assertions.rb:51:in
`assert_too_much_tag'
./rss/test_syndication.rb:50:in `test_parser'
./rss/test_syndication.rb:49:in `test_parser'


They both seem to have something to do with web features. I'm not sure
if it was because something else was running and didn't let go of the
previous Ruby libs in memory, and now has been refreshed, because I
can't get the tests to fail now.

Sean
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,810
Latest member
Kassie0918

Latest Threads

Top