rake spec:rcov => [BUG] Segmentation fault ruby 1.8.6 (2007-09-24)[i386-mswin32]

S

scott

i have a rails app that tests fine with "rake spec" but gets a
segmentation fault when "rake spec:rcov" is run.
i am on windows xp, ruby 1.8.6, rails 2.1.1, mysql 5

my app is at
http://github.com/scottnj/test_blog/tree/master
so maybe someone can try to replicate my error so i know if the
problem is with my code or something installed on my pc.

here is a copy of my shell output

(in C:/Documents and Settings/Scott/My Documents/NetBeansProjects/
blog)
** Invoke spec:rcov (first_time)
** Invoke spec:clobber_rcov (first_time)
** Execute spec:clobber_rcov
** Execute spec:rcov
.......................................................................................................................generated
code (c:/ruby/lib/ruby/gems/1.8/gems/actionpack-2.1.1/lib/
action_controller/routing/route.rb:86):1: [BUG] Segmentation fault
ruby 1.8.6 (2007-09-24) [i386-mswin32]


This application has requested the Runtime to terminate it in an
unusual way.
Please contact the application's support team for more information.
rake aborted!
Command c:/ruby/bin/ruby -I"C:/Documents and Settings/Scott/My
Documents/NetBeansProjects/blog/vendor/plugins/rspec/lib" -S rcov --
exclude "spec/*,gems/*" --rails -o "coverage" "C:/Documents and
Settings/Scott/My Documents/NetBeansProjects/blog/vendor/plugins/rspec/
bin/spec" -- "spec/controllers/access_control_spec.rb" "spec/
controllers/authenticated_system_spec.rb" "spec/controllers/
blogs_controller_spec.rb" "spec/controllers/blogs_routing_spec.rb"
"spec/controllers/sessions_controller_spec.rb" "spec/controllers/
users_controller_spec.rb" "spec/helpers/blogs_helper_spec.rb" "spec/
helpers/users_helper_spec.rb" "spec/models/blog_spec.rb" "spec/models/
user_spec.rb" "spec/views/blogs/edit.html.erb_spec.rb" "spec/views/
blogs/index.html.erb_spec.rb" "spec/views/blogs/new.html.erb_spec.rb"
"spec/views/blogs/show.html.erb_spec.rb" --options "
C:/Documents and Settings/Scott/My Documents/NetBeansProjects/blog/
spec/spec.opts" failed
C:/Documents and Settings/Scott/My Documents/NetBeansProjects/blog/
vendor/plugins/rspec/lib/spec/rake/spectask.rb:177:in `define'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1003:in
`verbose'
C:/Documents and Settings/Scott/My Documents/NetBeansProjects/blog/
vendor/plugins/rspec/lib/spec/rake/spectask.rb:153:in `define'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:546:in `call'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:546:in `execute'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:541:in `each'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:541:in `execute'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:508:in
`invoke_with_call_chain'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:501:in
`synchronize'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:501:in
`invoke_with_call_chain'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:494:in `invoke'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1931:in
`invoke_task'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1909:in
`top_level'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1909:in `each'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1909:in
`top_level'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1948:in
`standard_exception_handling'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1903:in
`top_level'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1881:in `run'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1948:in
`standard_exception_handling'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1878:in `run'
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/bin/rake:31
c:/ruby/bin/rake:16:in `load'
c:/ruby/bin/rake:16
 
L

Luis Lavena

i have a rails app that tests fine with "rake spec" but gets a
segmentation fault when "rake spec:rcov" is run.
i am on windows xp, ruby 1.8.6, rails 2.1.1, mysql 5

my app is athttp://github.com/scottnj/test_blog/tree/master
so maybe someone can try to replicate my error so i know if the
problem is with my code or something installed on my pc.

here is a copy of my shell output

(in C:/Documents and Settings/Scott/My Documents/NetBeansProjects/
blog)
** Invoke spec:rcov (first_time)
** Invoke spec:clobber_rcov (first_time)
** Execute spec:clobber_rcov
** Execute spec:rcov
.......................................................................................................................generated
code (c:/ruby/lib/ruby/gems/1.8/gems/actionpack-2.1.1/lib/
action_controller/routing/route.rb:86):1: [BUG] Segmentation fault
ruby 1.8.6 (2007-09-24) [i386-mswin32]

This application has requested the Runtime to terminate it in an
unusual way.
Please contact the application's support team for more information.
rake aborted!

You could try changing your spec/spec.opts to offer more details
(instead of default progress maybe spec format).

That will be more simple than for us replicate your exact environment
(ruby version, gem and such).

Regards,
 
S

scott

i added --spec format to the bottom of my spec.opts so it looks like
this
--colour
--format progress
--loadby mtime
--reverse
--spec format

i'm not sure if this is what you meant. i did a quick search on google
for some documentation on this file but didn't find anything.
anyway, now i am not getting the segmentation fault but "0 examples, 0
failures" so i think i'm doing something wrong.
(in C:/Documents and Settings/Scott/My Documents/NetBeansProjects/
blog)
** Invoke spec:rcov (first_time)
** Invoke spec:clobber_rcov (first_time)
** Execute spec:clobber_rcov
** Execute spec:rcov
Finished in 1.594 seconds
0 examples, 0 failures


i have a rails app that tests fine with "rake spec" but gets a
segmentation fault when "rake spec:rcov" is run.
i am on windows xp, ruby 1.8.6, rails 2.1.1, mysql 5
my app is athttp://github.com/scottnj/test_blog/tree/master
so maybe someone can try to replicate my error so i know if the
problem is with my code or something installed on my pc.
here is a copy of my shell output
(in C:/Documents and Settings/Scott/My Documents/NetBeansProjects/
blog)
** Invoke spec:rcov (first_time)
** Invoke spec:clobber_rcov (first_time)
** Execute spec:clobber_rcov
** Execute spec:rcov
.......................................................................................................................generated
code (c:/ruby/lib/ruby/gems/1.8/gems/actionpack-2.1.1/lib/
action_controller/routing/route.rb:86):1: [BUG] Segmentation fault
ruby 1.8.6 (2007-09-24) [i386-mswin32]
This application has requested the Runtime to terminate it in an
unusual way.
Please contact the application's support team for more information.
rake aborted!

You could try changing your spec/spec.opts to offer more details
(instead of default progress maybe spec format).

That will be more simple than for us replicate your exact environment
(ruby version, gem and such).

Regards,
 
L

Luis Lavena

i added --spec format to the bottom of my spec.opts so it looks like
this
--colour
--format progress
--loadby mtime
--reverse
--spec format

spec --help:

Builtin formats for examples:
progress|p : Text progress
profile|o : Text progress with profiling of 10 slowest
examples
specdoc|s : Example doc as text
html|h : A nice HTML report

so you need to change --format to: specdoc (and remove the --spec one)
i'm not sure if this is what you meant. i did a quick search on google
for some documentation on this file but didn't find anything.
anyway, now i am not getting the segmentation fault but "0 examples, 0
failures" so i think i'm doing something wrong.

You're not getting segfault because your code is not being executed :-
D

Change the spec.opts options again and let us know :)

Regards,
 
S

scott

--colour
--format specdoc
--loadby mtime
--reverse

still gives the seg-fault?

c:/ruby/lib/ruby/gems/1.8/gems/actionmailer-2.1.1/lib/action_mailer/
vendor/tmail-1.2.3/tmail/port.rb:343: [BUG] Segmentation fault
ruby 1.8.6 (2007-09-24) [i386-mswin32]
 
L

Luis Lavena

Scott said:
--colour
--format specdoc
--loadby mtime
--reverse

still gives the seg-fault?

c:/ruby/lib/ruby/gems/1.8/gems/actionmailer-2.1.1/lib/action_mailer/
vendor/tmail-1.2.3/tmail/port.rb:343: [BUG] Segmentation fault
ruby 1.8.6 (2007-09-24) [i386-mswin32]

This only happens to you while running specs with rcov, correct?

Based on your first message and the last one, it seems the segmentation
fault is random (not always happens in the same place).

Maybe there is something in rspec or rcov that is affecting the runtime
stability.

Will try to clone your repo and see what I can find.

Regards,
 

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,744
Messages
2,569,484
Members
44,904
Latest member
HealthyVisionsCBDPrice

Latest Threads

Top