Closed Electrickal closed 1 year ago
Alternative attempt using bundler:
% bundle install
Fetching gem metadata from https://rubygems.org/.
Resolving dependencies...
Using bundler 2.4.12
Using chess 0.3.3
Bundle complete! 1 Gemfile dependency, 2 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.
% bundle exec ruby test_chess_require.rb
<internal:/Users/electrick/.asdf/installs/ruby/3.2.2/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require': cannot load such file -- /Users/electrick/.asdf/installs/ruby/3.2.2/lib/ruby/gems/3.2.0/gems/chess-0.3.3/lib/chess/../../ext/chess (LoadError)
from <internal:/Users/electrick/.asdf/installs/ruby/3.2.2/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
from /Users/electrick/.asdf/installs/ruby/3.2.2/lib/ruby/gems/3.2.0/gems/chess-0.3.3/lib/chess/game.rb:1:in `<top (required)>'
from <internal:/Users/electrick/.asdf/installs/ruby/3.2.2/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
from <internal:/Users/electrick/.asdf/installs/ruby/3.2.2/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
from /Users/electrick/.asdf/installs/ruby/3.2.2/lib/ruby/gems/3.2.0/gems/chess-0.3.3/lib/chess.rb:2:in `<top (required)>'
from <internal:/Users/electrick/.asdf/installs/ruby/3.2.2/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
from <internal:/Users/electrick/.asdf/installs/ruby/3.2.2/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
from test_chess_require.rb:1:in `<main>'
Ok, I've found the problem. I'll release a fix in ASAP.
Seems that with ruby 3.2 the bundle file generated by the Makefile is saved in lib/chess
, while before in ext/chess
.
@Electrickal I've just pushed version 0.3.4. Let me know if this version fixes the problem.
Thank you very much for opening the issue.
That seems to have worked! Thanks @pioz, I'll let you know if anything else comes up. Consider this one closed 👍
I'm running into a roadblock with this gem where if I try to require it in any of my .rb's, i get thrown the same error. I've uninstalled and reinstalled multiple times, and these are the errors I get:
Uninstall gem
Re-Install Gem
Gem test file
Attempt to run test file (I get this same error output when I try to require the chess gem anywhere else in my code)
Thanks in advance for your help!