AndyObtiva / sample-glimmer-dsl-web-rails7-app

Sample Glimmer DSL for Web Rails 7 Application
MIT License
1 stars 0 forks source link

Noob problem from me: Your Ruby version is 3.2.0, but your Gemfile specified 3.0.2 #1

Open rubyFeedback opened 9 months ago

rubyFeedback commented 9 months ago

Hey there Andy,

I just git cloned the repository after "gem install rails".

Then I cd-ed into the directory and did:

bundle

Bundler then tells me this error:

Your Ruby version is 3.2.0, but your Gemfile specified 3.0.2

(If I were not such a bundler noob I can probably solve this myself, but I wanted to conform to the official instructions you gave on the main README for now. I'll try it again in the new year.)

Would it be possible to relax the requirements, if that is ok? Perhaps it does not work then, but if it works it would be nice to try out the sample you provide here, without changing the ruby version (I actually had an irb-related problem with ruby 3.3.0 so I downgraded again to 3.2.0; need to fix a lot of things in my own local code base as well in the new year).

At any rate, 2023 is soon getting close to an end so happy new year - onto and towards glimmering (or glimmerifying) EVERYTHING in 2024! \o/

AndyObtiva commented 9 months ago

Locally on your machine, edit Gemfile and update this line to your Ruby version:

ruby "3.0.2"

So, it becomes:

ruby "3.2.0"

Afterwards, run “bundle”. If that doesn’t resolve the issue, run “bundle update” instead and see if that helps.

If your issue is resolved, please close it. I am keeping it open in case your issue is not resolved, in which case, share with me whatever error message you might get if any.

Have a happy new year too.

AndyObtiva commented 9 months ago

I just found out on a different machine that I cannot use Ruby 3.2.0 with this project. It only works with Ruby 3.0.2 because opal-jquery does not support Ruby versions newer than 3.0. I am going to contribute a fix to it to make it work with Ruby 3.2.0.

In the meantime, I recommend that you install the exact version required by this project to test it, that is 3.0.2. You also need to run rails db:migrate to create the database before being able to start the server with rails server (or rails s).