Hi,
I’m trying to package my first gem using Hoe (1.4.0) and am having
difficulties with Rake (0.8.1) on a Windows XP system. What I notice is
that when I execute the task through Rake, it will fail yet I can
execute the task outside of Rake. For instance:
C:\rubylogparser>rake install_gem
(in C:/rubylogparser)
zip -r rubylogparser-0.1.0.zip rubylogparser-0.1.0
Successfully built RubyGem
Name: rubylogparser
Version: 0.1.0
File: rubylogparser-0.1.0.gem
gem install pkg/.gem
rake aborted!
Command failed with status (0): [gem install pkg/.gem…]
(See full trace by running task with --trace)
C:\rubylogparser>rake install_gem --trace
(in C:/rubylogparser)
** Invoke install_gem (first_time)
** Invoke clean (first_time)
** Invoke clobber_docs (first_time)
** Execute clobber_docs
** Invoke clobber_package (first_time)
** Execute clobber_package
** Execute clean
** Invoke package (first_time)
** Invoke pkg/rubylogparser-0.1.0.zip (first_time)
** Invoke pkg/rubylogparser-0.1.0 (first_time)
** Invoke EXAMPLES.txt (first_time, not_needed)
** Invoke GUIDE.txt (first_time, not_needed)
** Invoke History.txt (first_time, not_needed)
** Invoke Manifest.txt (first_time, not_needed)
** Invoke README.txt (first_time, not_needed)
** Invoke Rakefile (first_time, not_needed)
** Invoke examples/event_log.rb (first_time, not_needed)
** Invoke examples/files.rb (first_time, not_needed)
** Invoke examples/queryinfo.rb (first_time, not_needed)
** Invoke examples/registry.rb (first_time, not_needed)
** Invoke lib/rubylogparser.rb (first_time, not_needed)
** Invoke test/test_rubylogparser.rb (first_time, not_needed)
** Execute pkg/rubylogparser-0.1.0
** Invoke EXAMPLES.txt (not_needed)
** Invoke GUIDE.txt (not_needed)
** Invoke History.txt (not_needed)
** Invoke Manifest.txt (not_needed)
** Invoke README.txt (not_needed)
** Invoke Rakefile (not_needed)
** Invoke examples/event_log.rb (not_needed)
** Invoke examples/files.rb (not_needed)
** Invoke examples/queryinfo.rb (not_needed)
** Invoke examples/registry.rb (not_needed)
** Invoke lib/rubylogparser.rb (not_needed)
** Invoke test/test_rubylogparser.rb (not_needed)
** Execute pkg/rubylogparser-0.1.0.zip
zip -r rubylogparser-0.1.0.zip rubylogparser-0.1.0
** Invoke gem (first_time)
** Invoke pkg/rubylogparser-0.1.0.gem (first_time)
** Invoke pkg (first_time, not_needed)
** Invoke EXAMPLES.txt (not_needed)
** Invoke GUIDE.txt (not_needed)
** Invoke History.txt (not_needed)
** Invoke Manifest.txt (not_needed)
** Invoke README.txt (not_needed)
** Invoke Rakefile (not_needed)
** Invoke examples/event_log.rb (not_needed)
** Invoke examples/files.rb (not_needed)
** Invoke examples/queryinfo.rb (not_needed)
** Invoke examples/registry.rb (not_needed)
** Invoke lib/rubylogparser.rb (not_needed)
** Invoke test/test_rubylogparser.rb (not_needed)
** Execute pkg/rubylogparser-0.1.0.gem
Successfully built RubyGem
Name: rubylogparser
Version: 0.1.0
File: rubylogparser-0.1.0.gem
** Execute gem
** Execute package
** Execute install_gem
gem install pkg/.gem
rake aborted!
Command failed with status (0): [gem install pkg/.gem…]
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:899:in sh' c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:906:in
call’
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:906:in sh' c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:985:in
sh’
c:/ruby/lib/ruby/gems/1.8/gems/hoe-1.4.0/lib/hoe.rb:486:in
define_tasks' 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_c
hain’
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_c
hain’
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_exceptio
n_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_exceptio n_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
C:\rubylogparser>gem install pkg/*.gem
Successfully installed rubylogparser, version 0.1.0
Installing ri documentation for rubylogparser-0.1.0…
Installing RDoc documentation for rubylogparser-0.1.0…
C:\rubylogparser>rake ridocs
(in C:/rubylogparser)
rdoc --ri -o ri .
rake aborted!
undefined method `exitstatus’ for nil:NilClass
(See full trace by running task with --trace)
C:\rubylogparser>rake ridocs --trace
(in C:/rubylogparser)
** Invoke ridocs (first_time)
** Invoke clean (first_time)
** Invoke clobber_docs (first_time)
** Execute clobber_docs
** Invoke clobber_package (first_time)
** Execute clobber_package
** Execute clean
** Execute ridocs
rdoc --ri -o ri .
rake aborted!
undefined method exitstatus' for nil:NilClass c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:899:in
sh’
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:906:in call' c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:906:in
sh’
c:/ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:985:in sh' c:/ruby/lib/ruby/gems/1.8/gems/hoe-1.4.0/lib/hoe.rb:546:in
define_tasks’
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_c hain' 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_c hain' 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_exceptio n_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_exceptio
n_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
C:\rubylogparser>rdoc --ri -o ri .
event_log.rb:
files.rb:
queryinfo.rb:
registry.rb:
rubylogparser.rb: c...............
test_rubylogparser.rb: c......
Generating RI…
Files: 6
Classes: 2
Modules: 0
Methods: 21
Elapsed: 1.803s
C:\rubylogparser>
Using Google, I see that I am not the only one who has seen these errors
in various incarnations. Does anyone understand why Rake fails when the
tasks succeed otherwise?
Thanks in advance,
Jim