Rails Server不会运行 [英] Rails Server will not run

查看:221
本文介绍了Rails Server不会运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

  $ rails服务器

在mac上的终端产生这两个错误,我试图通过卸载和安装ruby&

  localhost: 3000 

在浏览器中显示网页损坏,意味着rails无法正常运行。



作为一个完整的初学者,我如何简单地一步一步地解决这些问题以便让rails运行?

 忽略binding_of_caller-0.7.2,因为它的扩展没有被构建。试试:gem pristine binding_of_caller --version 0.7.2 
忽略byebug-8.2.2,因为它的扩展没有被构建。试试:gem pristine byebug --version 8.2.2
忽略debug_inspector-0.0.2,因为它的扩展没有构建。试试:gem pristine debug_inspector --version 0.0.2
忽略可执行文件钩子1.3.2,因为它的扩展没有被构建。试试:gem pristine executable-hooks --version 1.3.2
忽略gem-wrappers-1.2.7,因为它的扩展没有被构建。试试:gem pristine gem-wrappers --version 1.2.7
忽略mysql2-0.4.2,因为它的扩展没有被构建。试试:gem pristine mysql2 --version 0.4.2
忽略nokogiri-1.6.7.2,因为它的扩展没有被构建。试试:gem pristine nokogiri --version 1.6.7.2
忽略binding_of_caller-0.7.2,因为它的扩展没有构建。试试:gem pristine binding_of_caller --version 0.7.2
忽略byebug-8.2.2,因为它的扩展没有被构建。试试:gem pristine byebug --version 8.2.2
忽略debug_inspector-0.0.2,因为它的扩展没有构建。试试:gem pristine debug_inspector --version 0.0.2
忽略可执行文件钩子1.3.2,因为它的扩展没有被构建。试试:gem pristine executable-hooks --version 1.3.2
忽略gem-wrappers-1.2.7,因为它的扩展没有被构建。试试:gem pristine gem-wrappers --version 1.2.7
忽略mysql2-0.4.2,因为它的扩展没有被构建。试试:gem pristine mysql2 --version 0.4.2
忽略nokogiri-1.6.7.2,因为它的扩展没有被构建。尝试:gem pristine nokogiri --version 1.6.7.2
dyld:懒惰符号绑定失败:找不到符号:_rb_data_typed_object_alloc
引用自:/Users/Leviathan/.rvm/gems/ruby-2.2.1/ gems / debug_inspector-0.0.2 / lib / debug_inspector.bundle
预计:flat命名空间

dyld:找不到符号:_rb_data_typed_object_alloc
引用自:/ Users / Leviathan /。 rvm / gems / ruby​​-2.2.1 / gems / debug_inspector-0.0.2 / lib / debug_inspector.bundle
预计:平面命名空间

跟踪/ BPT陷阱:5


解决方案

编辑:尝试运行 gem pristine



尝试卸载并重新安装打包程序:

gem uninstall bundler 然后 gem install bundler



然后运行 bundle install



这将安装您应该在Gemfile中指定的所有宝石,以及所有扩展名。



例如捆绑包完成! 33个Gemfile依赖关系,现在安装了103个宝石。


Typing

$ rails server 

in terminal on mac yields these two errors that I've tried troubleshooting by uninstalling and installing ruby & rails again and get this same error.

Typing

localhost:3000 

on the browser brings a broken webpage meaning rails is not running properly.

As a complete beginner, how do i troubleshoot these problems below simply step by step to get rails to run?

Ignoring binding_of_caller-0.7.2 because its extensions are not built.  Try: gem pristine binding_of_caller --version 0.7.2
Ignoring byebug-8.2.2 because its extensions are not built.  Try: gem pristine byebug --version 8.2.2
Ignoring debug_inspector-0.0.2 because its extensions are not built.  Try: gem pristine debug_inspector --version 0.0.2
Ignoring executable-hooks-1.3.2 because its extensions are not built.  Try: gem pristine executable-hooks --version 1.3.2
Ignoring gem-wrappers-1.2.7 because its extensions are not built.  Try: gem pristine gem-wrappers --version 1.2.7
Ignoring mysql2-0.4.2 because its extensions are not built.  Try: gem pristine mysql2 --version 0.4.2
Ignoring nokogiri-1.6.7.2 because its extensions are not built.  Try: gem pristine nokogiri --version 1.6.7.2
Ignoring binding_of_caller-0.7.2 because its extensions are not built.  Try: gem pristine binding_of_caller --version 0.7.2
Ignoring byebug-8.2.2 because its extensions are not built.  Try: gem pristine byebug --version 8.2.2
Ignoring debug_inspector-0.0.2 because its extensions are not built.  Try: gem pristine debug_inspector --version 0.0.2
Ignoring executable-hooks-1.3.2 because its extensions are not built.  Try: gem pristine executable-hooks --version 1.3.2
Ignoring gem-wrappers-1.2.7 because its extensions are not built.  Try: gem pristine gem-wrappers --version 1.2.7
Ignoring mysql2-0.4.2 because its extensions are not built.  Try: gem pristine mysql2 --version 0.4.2
Ignoring nokogiri-1.6.7.2 because its extensions are not built.  Try: gem pristine nokogiri --version 1.6.7.2
dyld: lazy symbol binding failed: Symbol not found: _rb_data_typed_object_alloc
  Referenced from: /Users/Leviathan/.rvm/gems/ruby-2.2.1/gems/debug_inspector-0.0.2/lib/debug_inspector.bundle
  Expected in: flat namespace

dyld: Symbol not found: _rb_data_typed_object_alloc
  Referenced from: /Users/Leviathan/.rvm/gems/ruby-2.2.1/gems/debug_inspector-0.0.2/lib/debug_inspector.bundle
  Expected in: flat namespace

Trace/BPT trap: 5

解决方案

EDIT: try running gem pristine --all first.

Try uninstalling and reinstalling bundler:

gem uninstall bundler then gem install bundler

Then run bundle install.

This will install all the gems you should have specified in your Gemfile, as well as all the extensions.

E.g Bundle complete! 33 Gemfile dependencies, 103 gems now installed.

这篇关于Rails Server不会运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆