[英]cannot load such file — pty (LoadError)
Completely new to Ruby on Rails. Ruby on Rails的全新内容。 My environment is Windows 2008 R2, and I just use the RailsInstaller to set it up. 我的环境是Windows 2008 R2,我只使用RailsInstaller进行设置。 I was given a website, so I placed it under C:\\Sites. 我得到了一个网站,所以将其放在C:\\ Sites下。 I followed the guide, and installed rails, as you can see the version down there in the code. 我遵循了指南,并安装了滑轨,因为您可以在代码下面看到它的版本。 Then I ran "rails server" to try to start the service, but I was given error message about "therubyracer-heroku-0.8.1.pre3 not installed, so I did a gem install and bundle install after that. Then therubyracer-heroku threw bunch of error, so I looked that up, told me I need to wrap it in a group, which I did and removed from production group within the gem file. Now when I do a "bundle install" everything is good, so I proceed with "rails server" and I got the error message down below. Any help ? please 然后,我运行“ rails服务器”以尝试启动该服务,但是收到有关“未安装therubyracer-heroku-0.8.1.pre3的错误消息,因此我进行了gem install并捆绑安装。然后,therubyracer-heroku抛出一堆错误,所以我抬起头,告诉我我需要将其包装到一个组中,然后将其打包并从gem文件中的生产组中删除。现在,当我执行“捆绑安装”时,一切都很好,所以我继续“ rails server”,我在下面得到了错误消息。有帮助吗?
source 'https://rubygems.org'
ruby '1.9.3'
gem 'rails', '3.2.13'
gem 'pg'
gem 'hashie'
gem 'figaro' # handles app configurations
gem 'airbrake' # exception/error tracking service
gem 'haml'
gem 'validates_existence', '>= 0.4'
gem 'useragent'
gem 'heroku'
group :development do
gem 'zeus' # speeds up loading of console and server
gem 'better_errors' # nicely-formatted UI of errors
gem 'binding_of_caller' # allows real-time debugging on error breakpoints
gem 'therubyracer', :platforms => :ruby, :require => 'v8'
end
group :production do
end
# Gems used only for assets and not required
# in production environments by default.
group :assets do
end
gem 'sass-rails', '~> 3.2.5'
gem 'coffee-rails', '~> 3.2.2'
gem 'uglifier'
gem 'jquery-rails'
gem 'prototype-rails'
gem 'coffee-filter'
-The Error output -错误输出
Rails 3.2.13
ruby 1.9.3p429 (2013-05-15) [i386-mingw32]
$ rails server
c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/activesupport-3.2.13/lib/ac
tive_support/dependencies.rb:251:in `require': cannot load such file -- pty (LoadError)
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `block in require'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:236:in `load_dependency'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `require'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/zeus-0.13.3/lib/zeus.rb:4:in `<top (required)>'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in `require'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in `block (2 levels) in require'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in `each'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in `block in require'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in `each'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in `require'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler.rb:132:in `require'
from c:/Sites/rct/config/application.rb:7:in `<top (required)>'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/railties-3.2.13/lib/rails/commands.rb:53:in `require'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/railties-3.2.13/lib/rails/commands.rb:53:in `block in <top (required)>'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/railties-3.2.13/lib/rails/commands.rb:50:in `tap'
from c:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/railties-3.2.13/lib/rails/commands.rb:50:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
The zeus
gem requires Linux or Mac OS X See https://github.com/burke/zeus zeus
gem需要Linux或Mac OS X,请参阅https://github.com/burke/zeus
Remove the zeus gem from your Gemfile, run bundle install
, and then retry rails server
从Gemfile中删除zeus gem,运行bundle install
,然后重试rails server
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.