Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade to Ruby v3 and Rails v7 #2183

Merged
merged 25 commits into from
May 9, 2023
Merged

Conversation

uzorjchibuzor
Copy link
Contributor

Closes #2116

@julianguyen
Copy link
Member

The CI failure that's happening:

#!/bin/bash --login
bundle install --path=vendor/bundle --jobs=4 --retry=3
[DEPRECATED] The `--path` flag is deprecated because it relies on being remembered across bundler invocations, which bundler will no longer do in future versions. Instead please use `bundle config set --local path 'vendor/bundle'`, and stop using this flag
Your Ruby version is 3.0.3, but your Gemfile specified ~> 3.1.2

Exited with code exit status 18
CircleCI received exit code 18

Looks like it's the result of needed to update the Ruby version in our Circle CI config.

@uzorjchibuzor
Copy link
Contributor Author

yes, it the ruby version on the CI build file, I changed it when I went to 3.0.3, then forgot to do the same when I moved to 3.1.2

@uzorjchibuzor
Copy link
Contributor Author

The application is coming along nicely, I think I messed up the title part of the erb but I will fix that along the CI thing. oh, and the docker container has to go up too but that goes without saying.

Copy link
Contributor Author

@uzorjchibuzor uzorjchibuzor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for some reason that I have been unable to figure out, this line <title><%= render 'layouts/title' %></title> at application.html.erb is not working as expected. The title bar looks wonky.

@uzorjchibuzor
Copy link
Contributor Author

How can I have 4 failing tests locally and the CI blows up into the hundreds? :-)

@julianguyen
Copy link
Member

I'm getting as many test failures in CI when I check out your branch.

Looks like it's predominantly:

ActionView::Template::Error:
  Custom asset_path helper is not implemented

  Extend your environment context with a custom method.

      environment.context_class.class_eval do
        def asset_path(path, options = {})
        end
      end

This Stack Overflow post suggests you might want to pass a full filename (including the file extension).

@julianguyen
Copy link
Member

for some reason that I have been unable to figure out, this line <title><%= render 'layouts/title' %></title> at application.html.erb is not working as expected. The title bar looks wonky.

Can you show me a screenshot of what this looks like for you?

@uzorjchibuzor
Copy link
Contributor Author

Screen Shot 2022-10-26 at 5 58 50 PM

@julianguyen Here is the screenshot of the title bar.. I will check the SO post for information.

@julianguyen
Copy link
Member

Just checking in, any updates here or anything I can help with?

@uzorjchibuzor
Copy link
Contributor Author

My charger got burnt and I just got a new one. I am trying to reset...

@julianguyen
Copy link
Member

I'm going to revisit this in a few weeks 💜

@seanmarcia seanmarcia force-pushed the upgrade_ruby_3.1.2_rails_7 branch 3 times, most recently from 1112151 to 1479160 Compare April 9, 2023 15:44
@seanmarcia seanmarcia force-pushed the upgrade_ruby_3.1.2_rails_7 branch from 1479160 to 722c055 Compare April 9, 2023 15:58
@seanmarcia
Copy link
Contributor

I added a couple of commits to fix the title issue and the rest of the broken specs. The tests are all passing locally (needed to set the Cloudinary env variables!) and I'm trying to figure out the why circle-ci is failing them.

I suspect and am testing out a few things:

  • Precompiling assets
  • webpack
  • something else circleci specific

Will comment again if/when I figure it out

@seanmarcia
Copy link
Contributor

Looks like CircleCi is working? Not sure why it says rspec is failing when there are no failing tests. I'm definitely not a circleci expert.

@uzorjchibuzor
Copy link
Contributor Author

uzorjchibuzor commented Apr 9, 2023 via email

@seanmarcia seanmarcia force-pushed the upgrade_ruby_3.1.2_rails_7 branch 7 times, most recently from 56959c4 to e6f6941 Compare April 10, 2023 03:52
@seanmarcia
Copy link
Contributor

Still not sure why it is reporting rspec tests as failing.
I noticed the branch needed the version of ruby to be updated, which involved some circle-ci changes. Which was a lot of trial and error but I think it is mostly ready.

@seanmarcia seanmarcia force-pushed the upgrade_ruby_3.1.2_rails_7 branch 2 times, most recently from 0d51df4 to 7a9974c Compare April 16, 2023 16:12
@seanmarcia seanmarcia force-pushed the upgrade_ruby_3.1.2_rails_7 branch from 7a9974c to 3cb1f81 Compare April 16, 2023 16:36
@seanmarcia
Copy link
Contributor

Finally green. Looks like Circle-CI has issues with the latest version of simplecov so I had to downgrade it. There were also a couple of vulnerabilities that needed to be addressed but it looks like it is in a good place now.

Any interest in setting up the CI in GitHub actions?

@julianguyen
Copy link
Member

Thanks so much for picking this up @seanmarcia! Sorry I couldn't review this a few weeks ago!

Setting up with GitHub actions would be a great long-term route to explore, are you familiar with that Circle CI to GitHub actions conversion process @seanmarcia ?

Copy link
Member

@julianguyen julianguyen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pulled things down locally and things looks good to me!

@julianguyen julianguyen force-pushed the upgrade_ruby_3.1.2_rails_7 branch from 61c7001 to 3cb1f81 Compare May 9, 2023 02:37
@julianguyen julianguyen merged commit a6cc5ff into main May 9, 2023
@delete-merged-branch delete-merged-branch bot deleted the upgrade_ruby_3.1.2_rails_7 branch May 9, 2023 02:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update to latest Ruby (v3) and Rails (v7)
3 participants