From 9607b861ae0ad7ddd72a624eea6b1e7f673d480d Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Thu, 18 Jan 2024 15:52:28 -0500 Subject: [PATCH 01/13] Update dev.yml --- dev.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev.yml b/dev.yml index 3327f5df7..6d9736d38 100644 --- a/dev.yml +++ b/dev.yml @@ -5,7 +5,7 @@ name: shipit-engine type: rails up: - - homebrew: + - packages: - sqlite - ruby: version: 2.7.5 From 402eb77a1c13db2a1a2b8a4424f5e394dea7ea00 Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Thu, 18 Jan 2024 15:39:17 -0500 Subject: [PATCH 02/13] Rails 7.1.1 upgrade Update CHANGELOG.md --- .github/workflows/main.yml | 2 +- CHANGELOG.md | 2 ++ docs/setup.md | 2 +- script/cibuild | 4 ++-- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 6994a87c8..6efee0c9f 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -150,7 +150,7 @@ jobs: export SHIPIT_GEM_PATH="${PWD}" mkdir /tmp/new-app cd /tmp/new-app - gem install rails -v '~> 7.0.2' --no-document + gem install rails -v '~> 7.1.1' --no-document rails new shipit --skip-action-cable --skip-turbolinks --skip-action-mailer --skip-active-storage --skip-webpack-install --skip-action-mailbox --skip-action-text -m "${SHIPIT_GEM_PATH}/template.rb" env: SHIPIT_EDGE: "1" diff --git a/CHANGELOG.md b/CHANGELOG.md index cc7f00316..53f3ea8e6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,7 @@ # Unreleased +* Upgraded to Rails 7.1.1 + # 0.38.0 * Convert `commit_deployment_statuses.github_id` to bigint (#1312) diff --git a/docs/setup.md b/docs/setup.md index 4bf035fda..fbcf710f6 100644 --- a/docs/setup.md +++ b/docs/setup.md @@ -14,7 +14,7 @@ In the future we'd like to provide it fully packaged inside a Docker container, Shipit provides you with a Rails template. To bootstrap your Shipit installation: -1. If you don't have Rails installed, run this command: `gem install rails -v 7.0` +1. If you don't have Rails installed, run this command: `gem install rails -v 7.1.1` 2. Run this command: `rails _7.0_ new shipit --skip-action-cable --skip-turbolinks --skip-action-mailer --skip-active-storage --skip-webpack-install --skip-action-mailbox --skip-action-text -m https://raw.githubusercontent.com/Shopify/shipit-engine/main/template.rb` ## Creating the GitHub App diff --git a/script/cibuild b/script/cibuild index 3ed1e1a50..12d7377ac 100755 --- a/script/cibuild +++ b/script/cibuild @@ -38,8 +38,8 @@ case $SUITE in git config --global user.email "anonymous@example.com" git config --global user.name "Anonymous" - gem install rails -v 7.0 - rails _7.0_ new shipit -m "${TEMPLATE}" \ + gem install rails -v 7.1.1 + rails _7.1.1_ new shipit -m "${TEMPLATE}" \ --skip-action-cable \ --skip-turbolinks \ --skip-action-mailer \ From 1e5831b41a9564d97f56c2508eb2c93449df5f09 Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Fri, 19 Jan 2024 16:14:26 -0500 Subject: [PATCH 03/13] wip --- shipit-engine.gemspec | 2 +- template.rb | 6 +++--- test/dummy/config/application.rb | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/shipit-engine.gemspec b/shipit-engine.gemspec index 3ede910da..99ae08cea 100644 --- a/shipit-engine.gemspec +++ b/shipit-engine.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |s| s.add_dependency('octokit', '~> 4.20') s.add_dependency('omniauth-github', '~> 1.4') s.add_dependency('pubsubstub', '~> 0.2.0') - s.add_dependency('rails', '~> 7.0.0') + s.add_dependency('rails', '~> 7.1.1') s.add_dependency('rails-timeago', '~> 2.13.0') s.add_dependency('rails_autolink', '~> 1.1.6') s.add_dependency('rake') diff --git a/template.rb b/template.rb index 560d8f8de..7e2f24a10 100644 --- a/template.rb +++ b/template.rb @@ -3,8 +3,8 @@ if Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.7') raise Thor::Error, "You need at least Ruby 2.7 to install shipit" end -if Gem::Version.new(Rails::VERSION::STRING) < Gem::Version.new('7.0') - raise Thor::Error, "You need Rails 7.0 to install shipit" +if Gem::Version.new(Rails::VERSION::STRING) < Gem::Version.new('7.1.1') + raise Thor::Error, "You need Rails 7.1.1 to install shipit" end route %(mount Shipit::Engine, at: '/') @@ -124,7 +124,7 @@ end CODE -inject_into_file 'config/application.rb', after: "load_defaults 7.0\n" do +inject_into_file 'config/application.rb', after: "load_defaults 7.1\n" do "\n config.active_job.queue_adapter = :sidekiq\n" end diff --git a/test/dummy/config/application.rb b/test/dummy/config/application.rb index 99c43aac8..fe54eff24 100644 --- a/test/dummy/config/application.rb +++ b/test/dummy/config/application.rb @@ -17,6 +17,6 @@ module Shipit class Application < Rails::Application - config.load_defaults 7.0 + config.load_defaults 7.1 end end From ff98ab8ae0eeed7f815a240f995c5bdd00cce6ae Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Fri, 26 Jan 2024 10:59:38 -0500 Subject: [PATCH 04/13] Update Gemfile.lock --- Gemfile.lock | 165 ++++++++++++++++++++++++++++++--------------------- 1 file changed, 99 insertions(+), 66 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 2b125cfb3..6c2c819f8 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -16,7 +16,7 @@ PATH omniauth-github (~> 1.4) paquito pubsubstub (~> 0.2.0) - rails (~> 7.0.0) + rails (~> 7.1.1) rails-timeago (~> 2.13.0) rails_autolink (~> 1.1.6) rake @@ -33,73 +33,82 @@ PATH GEM remote: https://rubygems.org/ specs: - actioncable (7.0.7.2) - actionpack (= 7.0.7.2) - activesupport (= 7.0.7.2) + actioncable (7.1.3) + actionpack (= 7.1.3) + activesupport (= 7.1.3) nio4r (~> 2.0) websocket-driver (>= 0.6.1) - actionmailbox (7.0.7.2) - actionpack (= 7.0.7.2) - activejob (= 7.0.7.2) - activerecord (= 7.0.7.2) - activestorage (= 7.0.7.2) - activesupport (= 7.0.7.2) + zeitwerk (~> 2.6) + actionmailbox (7.1.3) + actionpack (= 7.1.3) + activejob (= 7.1.3) + activerecord (= 7.1.3) + activestorage (= 7.1.3) + activesupport (= 7.1.3) mail (>= 2.7.1) net-imap net-pop net-smtp - actionmailer (7.0.7.2) - actionpack (= 7.0.7.2) - actionview (= 7.0.7.2) - activejob (= 7.0.7.2) - activesupport (= 7.0.7.2) + actionmailer (7.1.3) + actionpack (= 7.1.3) + actionview (= 7.1.3) + activejob (= 7.1.3) + activesupport (= 7.1.3) mail (~> 2.5, >= 2.5.4) net-imap net-pop net-smtp - rails-dom-testing (~> 2.0) - actionpack (7.0.7.2) - actionview (= 7.0.7.2) - activesupport (= 7.0.7.2) - rack (~> 2.0, >= 2.2.4) + rails-dom-testing (~> 2.2) + actionpack (7.1.3) + actionview (= 7.1.3) + activesupport (= 7.1.3) + nokogiri (>= 1.8.5) + racc + rack (>= 2.2.4) + rack-session (>= 1.0.1) rack-test (>= 0.6.3) - rails-dom-testing (~> 2.0) - rails-html-sanitizer (~> 1.0, >= 1.2.0) - actiontext (7.0.7.2) - actionpack (= 7.0.7.2) - activerecord (= 7.0.7.2) - activestorage (= 7.0.7.2) - activesupport (= 7.0.7.2) + rails-dom-testing (~> 2.2) + rails-html-sanitizer (~> 1.6) + actiontext (7.1.3) + actionpack (= 7.1.3) + activerecord (= 7.1.3) + activestorage (= 7.1.3) + activesupport (= 7.1.3) globalid (>= 0.6.0) nokogiri (>= 1.8.5) - actionview (7.0.7.2) - activesupport (= 7.0.7.2) + actionview (7.1.3) + activesupport (= 7.1.3) builder (~> 3.1) - erubi (~> 1.4) - rails-dom-testing (~> 2.0) - rails-html-sanitizer (~> 1.1, >= 1.2.0) + erubi (~> 1.11) + rails-dom-testing (~> 2.2) + rails-html-sanitizer (~> 1.6) active_model_serializers (0.9.9) activemodel (>= 3.2) concurrent-ruby (~> 1.0) - activejob (7.0.7.2) - activesupport (= 7.0.7.2) + activejob (7.1.3) + activesupport (= 7.1.3) globalid (>= 0.3.6) - activemodel (7.0.7.2) - activesupport (= 7.0.7.2) - activerecord (7.0.7.2) - activemodel (= 7.0.7.2) - activesupport (= 7.0.7.2) - activestorage (7.0.7.2) - actionpack (= 7.0.7.2) - activejob (= 7.0.7.2) - activerecord (= 7.0.7.2) - activesupport (= 7.0.7.2) + activemodel (7.1.3) + activesupport (= 7.1.3) + activerecord (7.1.3) + activemodel (= 7.1.3) + activesupport (= 7.1.3) + timeout (>= 0.4.0) + activestorage (7.1.3) + actionpack (= 7.1.3) + activejob (= 7.1.3) + activerecord (= 7.1.3) + activesupport (= 7.1.3) marcel (~> 1.0) - mini_mime (>= 1.1.0) - activesupport (7.0.7.2) + activesupport (7.1.3) + base64 + bigdecimal concurrent-ruby (~> 1.0, >= 1.0.2) + connection_pool (>= 2.2.5) + drb i18n (>= 1.6, < 2) minitest (>= 5.1) + mutex_m tzinfo (~> 2.0) addressable (2.8.0) public_suffix (>= 2.0.2, < 5.0) @@ -111,6 +120,8 @@ GEM descendants_tracker (~> 0.0.4) ice_nine (~> 0.11.0) thread_safe (~> 0.3, >= 0.3.1) + base64 (0.2.0) + bigdecimal (3.1.6) builder (3.2.4) byebug (11.1.3) coderay (1.1.3) @@ -124,6 +135,7 @@ GEM execjs coffee-script-source (1.12.2) concurrent-ruby (1.2.2) + connection_pool (2.4.1) crack (0.4.5) rexml crass (1.0.6) @@ -131,6 +143,8 @@ GEM descendants_tracker (0.0.4) thread_safe (~> 0.3, >= 0.3.1) docile (1.4.0) + drb (2.2.0) + ruby2_keywords equalizer (0.0.11) erubi (1.12.0) execjs (2.8.1) @@ -174,6 +188,10 @@ GEM i18n (1.14.1) concurrent-ruby (~> 1.0) ice_nine (0.11.2) + io-console (0.7.2) + irb (1.11.1) + rdoc + reline (>= 0.4.2) jquery-rails (4.6.0) rails-dom-testing (>= 1, < 3) railties (>= 4.2.0) @@ -203,6 +221,7 @@ GEM msgpack (1.7.1) multi_xml (0.6.0) multipart-post (2.3.0) + mutex_m (0.2.0) mysql2 (0.5.3) net-imap (0.3.6) date @@ -248,29 +267,36 @@ GEM pry (0.14.1) coderay (~> 1.1) method_source (~> 1.0) + psych (5.1.2) + stringio public_suffix (4.0.6) pubsubstub (0.2.2) rack redis (~> 4.0) racc (1.7.1) rack (2.2.7) + rack-session (1.0.2) + rack (< 3) rack-test (2.1.0) rack (>= 1.3) - rails (7.0.7.2) - actioncable (= 7.0.7.2) - actionmailbox (= 7.0.7.2) - actionmailer (= 7.0.7.2) - actionpack (= 7.0.7.2) - actiontext (= 7.0.7.2) - actionview (= 7.0.7.2) - activejob (= 7.0.7.2) - activemodel (= 7.0.7.2) - activerecord (= 7.0.7.2) - activestorage (= 7.0.7.2) - activesupport (= 7.0.7.2) + rackup (1.0.0) + rack (< 3) + webrick + rails (7.1.3) + actioncable (= 7.1.3) + actionmailbox (= 7.1.3) + actionmailer (= 7.1.3) + actionpack (= 7.1.3) + actiontext (= 7.1.3) + actionview (= 7.1.3) + activejob (= 7.1.3) + activemodel (= 7.1.3) + activerecord (= 7.1.3) + activestorage (= 7.1.3) + activesupport (= 7.1.3) bundler (>= 1.15.0) - railties (= 7.0.7.2) - rails-dom-testing (2.1.1) + railties (= 7.1.3) + rails-dom-testing (2.2.0) activesupport (>= 5.0.0) minitest nokogiri (>= 1.6) @@ -284,19 +310,24 @@ GEM actionview (> 3.1) activesupport (> 3.1) railties (> 3.1) - railties (7.0.7.2) - actionpack (= 7.0.7.2) - activesupport (= 7.0.7.2) - method_source + railties (7.1.3) + actionpack (= 7.1.3) + activesupport (= 7.1.3) + irb + rackup (>= 1.0.0) rake (>= 12.2) - thor (~> 1.0) - zeitwerk (~> 2.5) + thor (~> 1.0, >= 1.2.2) + zeitwerk (~> 2.6) rainbow (3.1.1) rake (13.0.6) + rdoc (6.6.2) + psych (>= 4.0.0) redis (4.8.1) redis-objects (1.7.0) redis regexp_parser (2.2.1) + reline (0.4.2) + io-console (~> 0.5) responders (3.1.0) actionpack (>= 5.2) railties (>= 5.2) @@ -356,6 +387,7 @@ GEM state_machines-activerecord (0.8.0) activerecord (>= 5.1) state_machines-activemodel (>= 0.8.0) + stringio (3.1.0) thor (1.2.2) thread_safe (0.3.6) tilt (2.2.0) @@ -376,6 +408,7 @@ GEM addressable (>= 2.8.0) crack (>= 0.3.2) hashdiff (>= 0.4.0, < 2.0.0) + webrick (1.8.1) websocket-driver (0.7.5) websocket-extensions (>= 0.1.0) websocket-extensions (0.1.5) From 75085425c443cd502e911ea69f94e4d1db38a31c Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Tue, 23 Jan 2024 12:56:29 -0500 Subject: [PATCH 05/13] Update application.rb --- test/dummy/config/application.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/test/dummy/config/application.rb b/test/dummy/config/application.rb index fe54eff24..9a9a61c14 100644 --- a/test/dummy/config/application.rb +++ b/test/dummy/config/application.rb @@ -18,5 +18,6 @@ module Shipit class Application < Rails::Application config.load_defaults 7.1 + config.active_record.encryption.support_sha1_for_non_deterministic_encryption = true end end From 6dcb9702791ea4385f64bb392f8921e3db1821c7 Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Wed, 24 Jan 2024 12:12:14 -0500 Subject: [PATCH 06/13] Update merge_request_test.rb --- test/models/merge_request_test.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/test/models/merge_request_test.rb b/test/models/merge_request_test.rb index 249d6a5c6..dc09ebcb6 100644 --- a/test/models/merge_request_test.rb +++ b/test/models/merge_request_test.rb @@ -243,7 +243,10 @@ class MergeRequestTest < ActiveSupport::TestCase end test "status transitions emit hooks" do - job = assert_enqueued_with(job: EmitEventJob) do + expected_args = ->(job_args) do + job_args.first[:event] == 'merge' + end + job = assert_enqueued_with(job: EmitEventJob, args: expected_args) do @pr.reject!('merge_conflict') end params = job.arguments.first From af3c0438e6ca55f2ed74559656eead3ba41bc734 Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Tue, 23 Jan 2024 18:09:38 -0500 Subject: [PATCH 07/13] Restrict to Rails 7.1.1 --- .github/workflows/main.yml | 2 +- shipit-engine.gemspec | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 6efee0c9f..9e27d30a1 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -150,7 +150,7 @@ jobs: export SHIPIT_GEM_PATH="${PWD}" mkdir /tmp/new-app cd /tmp/new-app - gem install rails -v '~> 7.1.1' --no-document + gem install rails -v '7.1.1' --no-document rails new shipit --skip-action-cable --skip-turbolinks --skip-action-mailer --skip-active-storage --skip-webpack-install --skip-action-mailbox --skip-action-text -m "${SHIPIT_GEM_PATH}/template.rb" env: SHIPIT_EDGE: "1" diff --git a/shipit-engine.gemspec b/shipit-engine.gemspec index 99ae08cea..054a7a589 100644 --- a/shipit-engine.gemspec +++ b/shipit-engine.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |s| s.add_dependency('octokit', '~> 4.20') s.add_dependency('omniauth-github', '~> 1.4') s.add_dependency('pubsubstub', '~> 0.2.0') - s.add_dependency('rails', '~> 7.1.1') + s.add_dependency('rails', '= 7.1.1') s.add_dependency('rails-timeago', '~> 2.13.0') s.add_dependency('rails_autolink', '~> 1.1.6') s.add_dependency('rake') From 1214962a99f0a7a8c90dd2646112ebfba3158233 Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Fri, 26 Jan 2024 11:15:34 -0500 Subject: [PATCH 08/13] Update Gemfile.lock --- Gemfile.lock | 151 +++++++++++++++++++++++++-------------------------- 1 file changed, 75 insertions(+), 76 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 6c2c819f8..2af1e3003 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -16,7 +16,7 @@ PATH omniauth-github (~> 1.4) paquito pubsubstub (~> 0.2.0) - rails (~> 7.1.1) + rails (= 7.1.1) rails-timeago (~> 2.13.0) rails_autolink (~> 1.1.6) rake @@ -33,51 +33,50 @@ PATH GEM remote: https://rubygems.org/ specs: - actioncable (7.1.3) - actionpack (= 7.1.3) - activesupport (= 7.1.3) + actioncable (7.1.1) + actionpack (= 7.1.1) + activesupport (= 7.1.1) nio4r (~> 2.0) websocket-driver (>= 0.6.1) zeitwerk (~> 2.6) - actionmailbox (7.1.3) - actionpack (= 7.1.3) - activejob (= 7.1.3) - activerecord (= 7.1.3) - activestorage (= 7.1.3) - activesupport (= 7.1.3) + actionmailbox (7.1.1) + actionpack (= 7.1.1) + activejob (= 7.1.1) + activerecord (= 7.1.1) + activestorage (= 7.1.1) + activesupport (= 7.1.1) mail (>= 2.7.1) net-imap net-pop net-smtp - actionmailer (7.1.3) - actionpack (= 7.1.3) - actionview (= 7.1.3) - activejob (= 7.1.3) - activesupport (= 7.1.3) + actionmailer (7.1.1) + actionpack (= 7.1.1) + actionview (= 7.1.1) + activejob (= 7.1.1) + activesupport (= 7.1.1) mail (~> 2.5, >= 2.5.4) net-imap net-pop net-smtp rails-dom-testing (~> 2.2) - actionpack (7.1.3) - actionview (= 7.1.3) - activesupport (= 7.1.3) + actionpack (7.1.1) + actionview (= 7.1.1) + activesupport (= 7.1.1) nokogiri (>= 1.8.5) - racc rack (>= 2.2.4) rack-session (>= 1.0.1) rack-test (>= 0.6.3) rails-dom-testing (~> 2.2) rails-html-sanitizer (~> 1.6) - actiontext (7.1.3) - actionpack (= 7.1.3) - activerecord (= 7.1.3) - activestorage (= 7.1.3) - activesupport (= 7.1.3) + actiontext (7.1.1) + actionpack (= 7.1.1) + activerecord (= 7.1.1) + activestorage (= 7.1.1) + activesupport (= 7.1.1) globalid (>= 0.6.0) nokogiri (>= 1.8.5) - actionview (7.1.3) - activesupport (= 7.1.3) + actionview (7.1.1) + activesupport (= 7.1.1) builder (~> 3.1) erubi (~> 1.11) rails-dom-testing (~> 2.2) @@ -85,22 +84,22 @@ GEM active_model_serializers (0.9.9) activemodel (>= 3.2) concurrent-ruby (~> 1.0) - activejob (7.1.3) - activesupport (= 7.1.3) + activejob (7.1.1) + activesupport (= 7.1.1) globalid (>= 0.3.6) - activemodel (7.1.3) - activesupport (= 7.1.3) - activerecord (7.1.3) - activemodel (= 7.1.3) - activesupport (= 7.1.3) + activemodel (7.1.1) + activesupport (= 7.1.1) + activerecord (7.1.1) + activemodel (= 7.1.1) + activesupport (= 7.1.1) timeout (>= 0.4.0) - activestorage (7.1.3) - actionpack (= 7.1.3) - activejob (= 7.1.3) - activerecord (= 7.1.3) - activesupport (= 7.1.3) + activestorage (7.1.1) + actionpack (= 7.1.1) + activejob (= 7.1.1) + activerecord (= 7.1.1) + activesupport (= 7.1.1) marcel (~> 1.0) - activesupport (7.1.3) + activesupport (7.1.1) base64 bigdecimal concurrent-ruby (~> 1.0, >= 1.0.2) @@ -134,12 +133,12 @@ GEM coffee-script-source execjs coffee-script-source (1.12.2) - concurrent-ruby (1.2.2) + concurrent-ruby (1.2.3) connection_pool (2.4.1) crack (0.4.5) rexml crass (1.0.6) - date (3.3.3) + date (3.3.4) descendants_tracker (0.0.4) thread_safe (~> 0.3, >= 0.3.1) docile (1.4.0) @@ -181,8 +180,8 @@ GEM faraday-retry (1.0.3) ffi (1.15.5) gemoji (2.1.0) - globalid (1.1.0) - activesupport (>= 5.0) + globalid (1.2.1) + activesupport (>= 6.1) hashdiff (1.0.1) hashie (5.0.0) i18n (1.14.1) @@ -202,7 +201,7 @@ GEM libv8-node (16.10.0.0-x86_64-linux) lodash-rails (4.17.21) railties (>= 3.1) - loofah (2.21.3) + loofah (2.22.0) crass (~> 1.0.2) nokogiri (>= 1.12.0) mail (2.8.1) @@ -212,10 +211,10 @@ GEM net-smtp marcel (1.0.2) method_source (1.0.0) - mini_mime (1.1.2) + mini_mime (1.1.5) mini_racer (0.6.2) libv8-node (~> 16.10.0.0) - minitest (5.19.0) + minitest (5.21.2) mocha (2.1.0) ruby2_keywords (>= 0.0.5) msgpack (1.7.1) @@ -223,21 +222,21 @@ GEM multipart-post (2.3.0) mutex_m (0.2.0) mysql2 (0.5.3) - net-imap (0.3.6) + net-imap (0.4.9.1) date net-protocol net-pop (0.1.2) net-protocol - net-protocol (0.2.1) + net-protocol (0.2.2) timeout - net-smtp (0.3.3) + net-smtp (0.4.0.1) net-protocol - nio4r (2.5.9) - nokogiri (1.15.2-arm64-darwin) + nio4r (2.7.0) + nokogiri (1.15.5-arm64-darwin) racc (~> 1.4) - nokogiri (1.15.2-x86_64-darwin) + nokogiri (1.15.5-x86_64-darwin) racc (~> 1.4) - nokogiri (1.15.2-x86_64-linux) + nokogiri (1.15.5-x86_64-linux) racc (~> 1.4) oauth2 (2.0.9) faraday (>= 0.17.3, < 3.0) @@ -273,8 +272,8 @@ GEM pubsubstub (0.2.2) rack redis (~> 4.0) - racc (1.7.1) - rack (2.2.7) + racc (1.7.3) + rack (2.2.8) rack-session (1.0.2) rack (< 3) rack-test (2.1.0) @@ -282,20 +281,20 @@ GEM rackup (1.0.0) rack (< 3) webrick - rails (7.1.3) - actioncable (= 7.1.3) - actionmailbox (= 7.1.3) - actionmailer (= 7.1.3) - actionpack (= 7.1.3) - actiontext (= 7.1.3) - actionview (= 7.1.3) - activejob (= 7.1.3) - activemodel (= 7.1.3) - activerecord (= 7.1.3) - activestorage (= 7.1.3) - activesupport (= 7.1.3) + rails (7.1.1) + actioncable (= 7.1.1) + actionmailbox (= 7.1.1) + actionmailer (= 7.1.1) + actionpack (= 7.1.1) + actiontext (= 7.1.1) + actionview (= 7.1.1) + activejob (= 7.1.1) + activemodel (= 7.1.1) + activerecord (= 7.1.1) + activestorage (= 7.1.1) + activesupport (= 7.1.1) bundler (>= 1.15.0) - railties (= 7.1.3) + railties (= 7.1.1) rails-dom-testing (2.2.0) activesupport (>= 5.0.0) minitest @@ -310,16 +309,16 @@ GEM actionview (> 3.1) activesupport (> 3.1) railties (> 3.1) - railties (7.1.3) - actionpack (= 7.1.3) - activesupport (= 7.1.3) + railties (7.1.1) + actionpack (= 7.1.1) + activesupport (= 7.1.1) irb rackup (>= 1.0.0) rake (>= 12.2) thor (~> 1.0, >= 1.2.2) zeitwerk (~> 2.6) rainbow (3.1.1) - rake (13.0.6) + rake (13.1.0) rdoc (6.6.2) psych (>= 4.0.0) redis (4.8.1) @@ -388,10 +387,10 @@ GEM activerecord (>= 5.1) state_machines-activemodel (>= 0.8.0) stringio (3.1.0) - thor (1.2.2) + thor (1.3.0) thread_safe (0.3.6) tilt (2.2.0) - timeout (0.4.0) + timeout (0.4.1) tzinfo (2.0.6) concurrent-ruby (~> 1.0) unicode-display_width (2.1.0) @@ -409,10 +408,10 @@ GEM crack (>= 0.3.2) hashdiff (>= 0.4.0, < 2.0.0) webrick (1.8.1) - websocket-driver (0.7.5) + websocket-driver (0.7.6) websocket-extensions (>= 0.1.0) websocket-extensions (0.1.5) - zeitwerk (2.6.8) + zeitwerk (2.6.12) PLATFORMS arm64-darwin-21 From ba2c64a58a014e2eb394e9f263d64892a9d3ef0d Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Fri, 26 Jan 2024 11:19:54 -0500 Subject: [PATCH 09/13] Fix failing setup ruby 2.7 step in some Github Actions --- Gemfile.lock | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 2af1e3003..f293118e8 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -196,9 +196,9 @@ GEM railties (>= 4.2.0) thor (>= 0.14, < 2.0) jwt (2.7.1) - libv8-node (16.10.0.0-arm64-darwin) - libv8-node (16.10.0.0-x86_64-darwin) - libv8-node (16.10.0.0-x86_64-linux) + libv8-node (16.19.0.1-arm64-darwin) + libv8-node (16.19.0.1-x86_64-darwin) + libv8-node (16.19.0.1-x86_64-linux) lodash-rails (4.17.21) railties (>= 3.1) loofah (2.22.0) @@ -212,8 +212,8 @@ GEM marcel (1.0.2) method_source (1.0.0) mini_mime (1.1.5) - mini_racer (0.6.2) - libv8-node (~> 16.10.0.0) + mini_racer (0.6.4) + libv8-node (~> 16.19.0.0) minitest (5.21.2) mocha (2.1.0) ruby2_keywords (>= 0.0.5) From 4f72beedc5c78014e8340baabc133341d8f13c4c Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Fri, 26 Jan 2024 13:20:11 -0500 Subject: [PATCH 10/13] Remove mini_racer gem --- Gemfile | 1 - Gemfile.lock | 6 ------ 2 files changed, 7 deletions(-) diff --git a/Gemfile b/Gemfile index e6c52fb4c..21ebd4a8c 100644 --- a/Gemfile +++ b/Gemfile @@ -25,5 +25,4 @@ end group :development, :test do gem 'byebug' gem 'pry' - gem 'mini_racer' end diff --git a/Gemfile.lock b/Gemfile.lock index f293118e8..bc11eee1a 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -196,9 +196,6 @@ GEM railties (>= 4.2.0) thor (>= 0.14, < 2.0) jwt (2.7.1) - libv8-node (16.19.0.1-arm64-darwin) - libv8-node (16.19.0.1-x86_64-darwin) - libv8-node (16.19.0.1-x86_64-linux) lodash-rails (4.17.21) railties (>= 3.1) loofah (2.22.0) @@ -212,8 +209,6 @@ GEM marcel (1.0.2) method_source (1.0.0) mini_mime (1.1.5) - mini_racer (0.6.4) - libv8-node (~> 16.19.0.0) minitest (5.21.2) mocha (2.1.0) ruby2_keywords (>= 0.0.5) @@ -422,7 +417,6 @@ PLATFORMS DEPENDENCIES byebug faker - mini_racer mocha mysql2 pg From 5329c4f3b357b41a43937aec5723a10764644cd3 Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Fri, 26 Jan 2024 13:34:05 -0500 Subject: [PATCH 11/13] Revert "Restrict to Rails 7.1.1" This reverts commit af3c0438e6ca55f2ed74559656eead3ba41bc734. --- .github/workflows/main.yml | 2 +- shipit-engine.gemspec | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 9e27d30a1..6efee0c9f 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -150,7 +150,7 @@ jobs: export SHIPIT_GEM_PATH="${PWD}" mkdir /tmp/new-app cd /tmp/new-app - gem install rails -v '7.1.1' --no-document + gem install rails -v '~> 7.1.1' --no-document rails new shipit --skip-action-cable --skip-turbolinks --skip-action-mailer --skip-active-storage --skip-webpack-install --skip-action-mailbox --skip-action-text -m "${SHIPIT_GEM_PATH}/template.rb" env: SHIPIT_EDGE: "1" diff --git a/shipit-engine.gemspec b/shipit-engine.gemspec index 054a7a589..99ae08cea 100644 --- a/shipit-engine.gemspec +++ b/shipit-engine.gemspec @@ -30,7 +30,7 @@ Gem::Specification.new do |s| s.add_dependency('octokit', '~> 4.20') s.add_dependency('omniauth-github', '~> 1.4') s.add_dependency('pubsubstub', '~> 0.2.0') - s.add_dependency('rails', '= 7.1.1') + s.add_dependency('rails', '~> 7.1.1') s.add_dependency('rails-timeago', '~> 2.13.0') s.add_dependency('rails_autolink', '~> 1.1.6') s.add_dependency('rake') From c1f65c4a7d59b0dee08e88a164b0282bc6ed051a Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Fri, 26 Jan 2024 13:35:47 -0500 Subject: [PATCH 12/13] Update Gemfile.lock --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index bc11eee1a..19e2cf230 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -16,7 +16,7 @@ PATH omniauth-github (~> 1.4) paquito pubsubstub (~> 0.2.0) - rails (= 7.1.1) + rails (~> 7.1.1) rails-timeago (~> 2.13.0) rails_autolink (~> 1.1.6) rake From 5550402492faf06794dcff3adc2fbe573fa51e91 Mon Sep 17 00:00:00 2001 From: Kartiki Sharma Date: Fri, 26 Jan 2024 15:31:29 -0500 Subject: [PATCH 13/13] Add minor tweaks --- docs/setup.md | 4 ++-- template.rb | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/setup.md b/docs/setup.md index fbcf710f6..ffbfc1727 100644 --- a/docs/setup.md +++ b/docs/setup.md @@ -14,8 +14,8 @@ In the future we'd like to provide it fully packaged inside a Docker container, Shipit provides you with a Rails template. To bootstrap your Shipit installation: -1. If you don't have Rails installed, run this command: `gem install rails -v 7.1.1` -2. Run this command: `rails _7.0_ new shipit --skip-action-cable --skip-turbolinks --skip-action-mailer --skip-active-storage --skip-webpack-install --skip-action-mailbox --skip-action-text -m https://raw.githubusercontent.com/Shopify/shipit-engine/main/template.rb` +1. If you don't have Rails installed, run this command: `gem install rails -v 7.1` +2. Run this command: `rails _7.1_ new shipit --skip-action-cable --skip-turbolinks --skip-action-mailer --skip-active-storage --skip-webpack-install --skip-action-mailbox --skip-action-text -m https://raw.githubusercontent.com/Shopify/shipit-engine/main/template.rb` ## Creating the GitHub App diff --git a/template.rb b/template.rb index 7e2f24a10..7f7b2cea4 100644 --- a/template.rb +++ b/template.rb @@ -3,8 +3,8 @@ if Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.7') raise Thor::Error, "You need at least Ruby 2.7 to install shipit" end -if Gem::Version.new(Rails::VERSION::STRING) < Gem::Version.new('7.1.1') - raise Thor::Error, "You need Rails 7.1.1 to install shipit" +if Gem::Version.new(Rails::VERSION::STRING) < Gem::Version.new('7.1') + raise Thor::Error, "You need Rails 7.1 to install shipit" end route %(mount Shipit::Engine, at: '/')