Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 0.9.8
-
Fix Version/s: 0.10.0
-
Component/s: Knife
-
Labels:None
-
Environment:
Vista 64
ruby 1.8.7 (2008-08-11 patchlevel 72) [i386-mswin32] (downloaded from ftp://ftp.ruby-lang.org/pub/ruby/binaries/mswin32/)
Description
When trying do do a knife cookbook upload, it bombs out on ruby 1.8.7 (2008-08-11 patchlevel 72) [i386-mswin32]
C:\Users\esposito\Documents\A\svnroot\developer\chef-repo>knife cookbook upload passenger_apache2
INFO: Saving passenger_apache2
INFO: Validating ruby files
c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/shell_out.rb:293:in `initialize_ipc': uninitialized constant Fcntl::F_SETFD (NameError)
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/shell_out.rb:375:in `fork_subprocess'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/shell_out.rb:158:in `run_command'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/mixin/shell_out.rb:26:in `shell_out'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/cookbook/syntax_check.rb:124:in `validate_ruby_file'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/cookbook/syntax_check.rb:98:in `validate_ruby_files'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/cookbook/syntax_check.rb:97:in `each'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/cookbook/syntax_check.rb:97:in `validate_ruby_files'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/cookbook_uploader.rb:93:in `validate_cookbook'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/cookbook_uploader.rb:19:in `upload_cookbook'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/knife/cookbook_upload.rb:67:in `run'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/knife/cookbook_upload.rb:65:in `each'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/knife/cookbook_upload.rb:65:in `run'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/knife/cookbook_upload.rb:80:in `humanize_auth_exceptions'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/knife/cookbook_upload.rb:53:in `run'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/knife.rb:127:in`run'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/lib/chef/application/knife.rb:118:in `run'
from c:/ruby/lib/ruby/gems/1.8/gems/chef-0.9.8/bin/knife:25
from c:/ruby/bin/knife:19:in `load'
from c:/ruby/bin/knife:19
When enumerating the list of constants in Fcntl, the list is very limited:
C:\Users\esposito\Documents\A\svnroot\developer\chef-repo>irb
irb(main):001:0> require 'fcntl'
=> true
irb(main):002:0> Fcntl.constants
=> ["O_EXCL", "O_ACCMODE", "O_NONBLOCK", "O_CREAT", "O_WRONLY", "O_APPEND", "F_SETFL", "O_RDWR", "O_TRUNC", "O_RDONLY"]
irb(main):003:0> quit
Also, I installed Ruby 1.9.2 and have the same problem; the constant is not defined:
ruby 1.9.2p0 (2010-08-18 revision 29036) [i386-mswin32]
C:\Users\esposito>irb
irb(main):001:0> require 'fcntl'
=> true
irb(main):002:0> Fcntl.constants
=> [:F_SETFL, :O_CREAT, :O_EXCL, :O_TRUNC, :O_APPEND, :O_NONBLOCK, :O_RDONLY, :O_RDWR, :O_WRONLY, :O_ACCMODE]
irb(main):003:0> quit
C:\Users\esposito>ruby -v
ruby 1.9.2p0 (2010-08-18 revision 29036) [i386-mswin32]