如何解决rails_admin:安装失败 - 错误的文件描述符错误
我正在尝试使用 rails_admin gem,但是当我运行命令 rails g rails_admin:install
时,我收到了错误的文件描述符错误。见下文。关于如何修复的任何想法?
C:/Ruby27-x64/lib/ruby/2.7.0/reline/ansi.rb:120:in `raw': Bad file descriptor (Errno::EBADF)
from C:/Ruby27-x64/lib/ruby/2.7.0/reline/ansi.rb:120:in `cursor_pos'
from C:/Ruby27-x64/lib/ruby/2.7.0/reline.rb:349:in `may_req_ambiguous_char_width'
from C:/Ruby27-x64/lib/ruby/2.7.0/reline.rb:208:in `inner_readline'
from C:/Ruby27-x64/lib/ruby/2.7.0/reline.rb:188:in `readline'
from C:/Ruby27-x64/lib/ruby/2.7.0/forwardable.rb:235:in `readline'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/line_editor/readline.rb:20:in `readline'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/line_editor.rb:7:in `readline'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/shell/basic.rb:439:in `ask_simply'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/shell/basic.rb:85:in `ask'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/shell.rb:60:in `ask'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/rails_admin-2.0.2/lib/generators/rails_admin/utils.rb:13:in `ask_for'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/rails_admin-2.0.2/lib/generators/rails_admin/install_generator.rb:13:in `install'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/command.rb:27:in `run'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/invocation.rb:127:in `invoke_command'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/invocation.rb:134:in `block in invoke_all'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/invocation.rb:134:in `each'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/invocation.rb:134:in `map'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/invocation.rb:134:in `invoke_all'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/group.rb:232:in `dispatch'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/base.rb:485:in `start'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/railties-6.1.1/lib/rails/generators.rb:275:in `invoke'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/railties-6.1.1/lib/rails/commands/generate/generate_command.rb:26:in `perform'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/command.rb:27:in `run'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor/invocation.rb:127:in `invoke_command'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/thor-1.0.1/lib/thor.rb:392:in `dispatch'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/railties-6.1.1/lib/rails/command/base.rb:69:in `perform'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/railties-6.1.1/lib/rails/command.rb:50:in `invoke'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/railties-6.1.1/lib/rails/commands.rb:18:in `<main>'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/bootsnap-1.5.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/bootsnap-1.5.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/bootsnap-1.5.1/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/bootsnap-1.5.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/bootsnap-1.5.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/activesupport-6.1.1/lib/active_support/dependencies.rb:332:in `block in require'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/activesupport-6.1.1/lib/active_support/dependencies.rb:299:in `load_dependency'
from C:/Ruby27-x64/lib/ruby/gems/2.7.0/gems/activesupport-6.1.1/lib/active_support/dependencies.rb:332:in `require'
from bin/rails:4:in `<main>'
系统规格:
- Windows 10 x64
- Ruby 2.7.2p137
- Rails 6.1.1
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。