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

Do not depend on entire Rails gem. #35

Closed
wants to merge 11 commits into from
Closed

Conversation

espen
Copy link
Contributor

@espen espen commented Jul 13, 2022

Fixes #34

@espen espen changed the title Do not depend on entire Rails gem. Fixes #34 Do not depend on entire Rails gem. Jul 13, 2022
@elct9620
Copy link
Owner

The test failed, please check it.

@espen
Copy link
Contributor Author

espen commented Jul 14, 2022

Sorry I have never used Travis before. I updated the Travis Gemfile.lock files now. How can I test this without pushing changes to the PR so that Travis runs? I am still getting an error: "Run bundle install elsewhere and add the updated gemfiles/rails_5.gemfile.lock to version control.". I ran bundle install --gemfile=rails_5.gemfile and pushed the updated Gemfile.lock.

Running the tests locally works btw.

@elct9620
Copy link
Owner

This gem use Appraisal to manage multiple rails version dependency. You need to use it to update all Gemfile.

@elct9620
Copy link
Owner

https://github.com/elct9620/rails-letsencrypt/blob/master/.travis.yml

The Rails 7 support is added but not listed in .travis.yml that it didn't be covered by automatic tests.

@elct9620
Copy link
Owner

Seems got some problem due to the bundler version still configured to 1.17.3, can you help to update it to 2.x?

@coveralls
Copy link

coveralls commented Jul 14, 2022

Coverage Status

Coverage remained the same at 88.316% when pulling ac032fd on espen:master into 14278e4 on elct9620:master.

@elct9620
Copy link
Owner

The gem dependency has some problems. I think we can drop 2.5 and add 2.7. 3.0.

@espen
Copy link
Contributor Author

espen commented Jul 14, 2022

Thanks for the pointers. I am new to Appraisals and Travis. Not sure why it is giving me an error now though:

You are trying to install in deployment mode after changing
your Gemfile. Run bundle install elsewhere and add the
updated gemfiles/rails_7.gemfile.lock to version control.
The lockfile does not have all gems needed for the current platform

I did bundle install and bundle exec appraisal install. Not sure what i can do now.

Is there any way to test this with Travis without pushing to the PR?

Sorry these commits are a bit of a mess now.

@espen
Copy link
Contributor Author

espen commented Jul 14, 2022

Fetching gem metadata from https://rubygems.org/..........
Your bundle is locked to railties (7.0.3.1) from rubygems repository
https://rubygems.org/ or installed locally, but that version can no longer be
found in that source. That means the author of railties (7.0.3.1) has removed
it. You'll need to update your bundle to a version other than railties (7.0.3.1)
that hasn't been removed in order to install.

Ok this is odd. Seems like there is some gem caching issue perhaps? Is it possible to trigger the test again?

@elct9620
Copy link
Owner

I had re-run the test for you. Maybe we can remove Travis CI and migrate to GitHub Actions later.

For the Gemfile lock issue, the appraisal gem should provide a way to help you update all Gemfile.lock before you push to the remove. You can check the document about how to update it and run the test in the different versions.

@espen
Copy link
Contributor Author

espen commented Jul 14, 2022

So now the Rails 7 test works for Ruby 2.7 but not for Ruby 2.6. It is saying railties 7.0.3.1 doesn't exist which is not correct. I think this could be a Travis issue.

@elct9620
Copy link
Owner

I have no idea about it. But you can check for Rails 7 is support Ruby 2.6 or not first 🤔

@espen espen marked this pull request as draft November 6, 2023 12:22
@espen
Copy link
Contributor Author

espen commented Nov 6, 2023

Closing in favour for #38 as this was done in my master branch and it doesn't seem possible to update the PR.

@espen espen closed this Nov 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Do not depend on the rails gem
3 participants