departure-next 6.7.1.pre.pre → 6.7.1.pre.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f2f14fb32023a58be4d0def6f553b67e7a59ecfa92e5319c66770f3c65ecbf22
4
- data.tar.gz: efee701ec70d435ed75b12e136c971d88f5bdf317739a5d7d196a1a6106ee363
3
+ metadata.gz: eb07f8bac571af6678ddf42ba37b0bafb8fabc1513ef7b7d7a93f6e54d4ec331
4
+ data.tar.gz: 800578f8114c7938e58c83ea2fa07500182446b6fe1ff07bd1f994b9f9d44d7f
5
5
  SHA512:
6
- metadata.gz: 7260d9268841719e1c0f0345907492f4fef64769e201d6f5a1ef7a3d8dc7a38d7d2add7654996f1e9436db5db62d5faafd4c493ec884f357e97a1b82863fa9b7
7
- data.tar.gz: 99c83d3d9415b0a54483ec5ba726cf5c93cc2559a682d977a6784c24af91fdad9552601c63b0ec660ba55f6c446e1e90e37c78a494d9d5ed86edf6754fa0d08c
6
+ metadata.gz: 6d4f66a78dd3af2f9087f4d0b29708eb31c61f5165ae61bb2bba11dcca1f282483dafbb9de4cd05498ce5576f3c9e2c3b1ec3b1426f863ea137be8fc03d098d3
7
+ data.tar.gz: 84dc1c70cd57f48906f4b405f6a65295eb74af00921d05f0b88292a16742408a52dae68e62634731f8f45e04a73e89654bbbbad60fc716b030a1320f7aa5533a
data/.rubocop.yml CHANGED
@@ -6,7 +6,7 @@ require:
6
6
  - rubocop-performance
7
7
 
8
8
  AllCops:
9
- TargetRubyVersion: 2.4
9
+ TargetRubyVersion: 3.1.x
10
10
 
11
11
  Metrics/AbcSize:
12
12
  Enabled: false
data/CHANGELOG.md CHANGED
@@ -11,8 +11,10 @@ Please follow the format in [Keep a Changelog](http://keepachangelog.com/)
11
11
  - Create a `bin/rails` command that loads the database from the dummy application
12
12
  - Create a RailsAdapter that will handle creating connections inside of different versions of rails
13
13
  - Implement a Rails72DeparatureAdapater that handles the differences between Rails 7.2 and other rails versions
14
+ - Implement a ActiveRecordMigratorWithAdvisoryLock for ActiveRecord versions 7.1 and 7.2 to prevent ConcurrentMigrationErrors
15
+ - Implement a configuration option `disable_rails_advisory_lock_patch` to disable the ActiveRecordMigratorWithAdvisoryLock patch in our gem
14
16
 
15
- ## [6.7.0] - 2024-02-20
17
+ ## [6.7.1.pre.2] - 2024-02-20
16
18
 
17
19
  - Flex mysql2 dependency to < 0.6 and bump version to 0.5.6
18
20
  - Drop support for older than the latest EOL Ruby (2.7) and Rails (6.0)
data/Gemfile CHANGED
@@ -7,5 +7,5 @@ gem 'codeclimate-test-reporter', '~> 1.0.3', group: :test, require: nil
7
7
  gem 'lhm'
8
8
  gem 'logger'
9
9
  gem 'mutex_m', require: false
10
- gem 'rubocop', '~> 1.60.2', require: false
10
+ gem 'rubocop', '~> 1.74.0', require: false
11
11
  gem 'rubocop-performance', '~> 1.20.2', require: false
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- departure-next (6.7.1.pre.pre)
4
+ departure (6.7.1.pre.2)
5
5
  activerecord (>= 6.0.0, < 7.3.0, != 7.0.0)
6
6
  mysql2 (>= 0.4.0, < 0.6.0)
7
7
  railties (>= 6.0.0, < 7.3.0, != 7.0.0)
@@ -48,7 +48,7 @@ GEM
48
48
  ast (2.4.2)
49
49
  base64 (0.2.0)
50
50
  bigdecimal (3.1.6)
51
- builder (3.3.0)
51
+ builder (3.2.4)
52
52
  byebug (11.1.3)
53
53
  climate_control (0.0.4)
54
54
  activesupport (>= 3.0)
@@ -58,64 +58,61 @@ GEM
58
58
  concurrent-ruby (1.2.3)
59
59
  connection_pool (2.4.1)
60
60
  crass (1.0.6)
61
- date (3.4.1)
62
61
  diff-lcs (1.5.1)
63
62
  docile (1.1.5)
64
63
  drb (2.2.0)
65
64
  ruby2_keywords
66
- erubi (1.13.1)
65
+ erubi (1.12.0)
67
66
  i18n (1.14.1)
68
67
  concurrent-ruby (~> 1.0)
69
- io-console (0.8.0)
70
- irb (1.15.1)
71
- pp (>= 0.6.0)
72
- rdoc (>= 4.0.0)
68
+ io-console (0.7.2)
69
+ irb (1.11.2)
70
+ rdoc
73
71
  reline (>= 0.4.2)
74
- json (2.7.1)
75
- language_server-protocol (3.17.0.3)
72
+ json (2.10.2)
73
+ language_server-protocol (3.17.0.4)
76
74
  lhm (2.2.0)
75
+ lint_roller (1.1.0)
77
76
  logger (1.6.6)
78
- loofah (2.24.0)
77
+ loofah (2.22.0)
79
78
  crass (~> 1.0.2)
80
79
  nokogiri (>= 1.12.0)
81
80
  method_source (1.0.0)
82
81
  minitest (5.22.2)
83
82
  mutex_m (0.2.0)
84
83
  mysql2 (0.5.6)
84
+ nokogiri (1.18.3-arm64-darwin)
85
+ racc (~> 1.4)
85
86
  nokogiri (1.18.3-x86_64-linux-gnu)
86
87
  racc (~> 1.4)
87
- parallel (1.24.0)
88
- parser (3.3.0.5)
88
+ parallel (1.26.3)
89
+ parser (3.3.7.1)
89
90
  ast (~> 2.4.1)
90
91
  racc
91
- pp (0.6.2)
92
- prettyprint
93
- prettyprint (0.2.0)
94
92
  pry (0.14.2)
95
93
  coderay (~> 1.1)
96
94
  method_source (~> 1.0)
97
95
  pry-byebug (3.10.1)
98
96
  byebug (~> 11.0)
99
97
  pry (>= 0.13, < 0.15)
100
- psych (5.2.3)
101
- date
98
+ psych (5.1.2)
102
99
  stringio
103
- racc (1.7.3)
104
- rack (3.1.11)
105
- rack-session (2.1.0)
106
- base64 (>= 0.1.0)
100
+ racc (1.8.1)
101
+ rack (3.0.9)
102
+ rack-session (2.0.0)
107
103
  rack (>= 3.0.0)
108
- rack-test (2.2.0)
104
+ rack-test (2.1.0)
109
105
  rack (>= 1.3)
110
- rackup (2.2.1)
106
+ rackup (2.1.0)
111
107
  rack (>= 3)
108
+ webrick (~> 1.8)
112
109
  rails-dom-testing (2.2.0)
113
110
  activesupport (>= 5.0.0)
114
111
  minitest
115
112
  nokogiri (>= 1.6)
116
- rails-html-sanitizer (1.6.2)
113
+ rails-html-sanitizer (1.6.0)
117
114
  loofah (~> 2.21)
118
- nokogiri (>= 1.15.7, != 1.16.7, != 1.16.6, != 1.16.5, != 1.16.4, != 1.16.3, != 1.16.2, != 1.16.1, != 1.16.0.rc1, != 1.16.0)
115
+ nokogiri (~> 1.14)
119
116
  railties (7.1.3)
120
117
  actionpack (= 7.1.3)
121
118
  activesupport (= 7.1.3)
@@ -126,12 +123,11 @@ GEM
126
123
  zeitwerk (~> 2.6)
127
124
  rainbow (3.1.1)
128
125
  rake (13.1.0)
129
- rdoc (6.12.0)
126
+ rdoc (6.6.2)
130
127
  psych (>= 4.0.0)
131
- regexp_parser (2.9.0)
132
- reline (0.6.0)
128
+ regexp_parser (2.10.0)
129
+ reline (0.4.2)
133
130
  io-console (~> 0.5)
134
- rexml (3.2.6)
135
131
  rspec (3.13.0)
136
132
  rspec-core (~> 3.13.0)
137
133
  rspec-expectations (~> 3.13.0)
@@ -148,19 +144,19 @@ GEM
148
144
  diff-lcs (>= 1.2.0, < 2.0)
149
145
  rspec-support (~> 3.13.0)
150
146
  rspec-support (3.13.0)
151
- rubocop (1.60.2)
147
+ rubocop (1.74.0)
152
148
  json (~> 2.3)
153
- language_server-protocol (>= 3.17.0)
149
+ language_server-protocol (~> 3.17.0.2)
150
+ lint_roller (~> 1.1.0)
154
151
  parallel (~> 1.10)
155
152
  parser (>= 3.3.0.2)
156
153
  rainbow (>= 2.2.2, < 4.0)
157
- regexp_parser (>= 1.8, < 3.0)
158
- rexml (>= 3.2.5, < 4.0)
159
- rubocop-ast (>= 1.30.0, < 2.0)
154
+ regexp_parser (>= 2.9.3, < 3.0)
155
+ rubocop-ast (>= 1.38.0, < 2.0)
160
156
  ruby-progressbar (~> 1.7)
161
- unicode-display_width (>= 2.4.0, < 3.0)
162
- rubocop-ast (1.30.0)
163
- parser (>= 3.2.1.0)
157
+ unicode-display_width (>= 2.4.0, < 4.0)
158
+ rubocop-ast (1.39.0)
159
+ parser (>= 3.3.1.0)
164
160
  rubocop-performance (1.20.2)
165
161
  rubocop (>= 1.48.1, < 2.0)
166
162
  rubocop-ast (>= 1.30.0, < 2.0)
@@ -171,13 +167,16 @@ GEM
171
167
  json (>= 1.8, < 3)
172
168
  simplecov-html (~> 0.10.0)
173
169
  simplecov-html (0.10.2)
174
- stringio (3.1.5)
170
+ stringio (3.1.0)
175
171
  thor (1.3.0)
176
- timeout (0.4.3)
172
+ timeout (0.4.1)
177
173
  tzinfo (2.0.6)
178
174
  concurrent-ruby (~> 1.0)
179
- unicode-display_width (2.5.0)
180
- zeitwerk (2.6.18)
175
+ unicode-display_width (3.1.4)
176
+ unicode-emoji (~> 4.0, >= 4.0.4)
177
+ unicode-emoji (4.0.4)
178
+ webrick (1.8.1)
179
+ zeitwerk (2.6.13)
181
180
 
182
181
  PLATFORMS
183
182
  arm64-darwin-21
@@ -191,7 +190,7 @@ DEPENDENCIES
191
190
  base64
192
191
  climate_control (~> 0.0.3)
193
192
  codeclimate-test-reporter (~> 1.0.3)
194
- departure-next!
193
+ departure!
195
194
  lhm
196
195
  logger
197
196
  mutex_m
@@ -199,7 +198,7 @@ DEPENDENCIES
199
198
  rake (>= 10.0)
200
199
  rspec (~> 3.4, >= 3.4.0)
201
200
  rspec-its (~> 1.2)
202
- rubocop (~> 1.60.2)
201
+ rubocop (~> 1.74.0)
203
202
  rubocop-performance (~> 1.20.2)
204
203
 
205
204
  BUNDLED WITH
data/README.md CHANGED
@@ -147,6 +147,14 @@ end
147
147
  It's strongly recommended to name it after this gems name, such as
148
148
  `config/initializers/departure.rb`
149
149
 
150
+ ### Configuration Options
151
+
152
+ All configuration options are configurable from the `Departure.configure` block example below
153
+
154
+ |Option|Default|What it Controls|
155
+ |---|---|---|
156
+ |disable_rails_advisory_lock_patch|false|When truthy, disables a patch in at least rails 7.1 and 7.2 where rails throws ConcurrentMigrationErrors due to the inability to release the advisory lock in migrations|
157
+
150
158
  ### Disable on per-migration basis
151
159
 
152
160
  Departure gem is enabled by default.
@@ -13,7 +13,7 @@ Gem::Specification.new do |spec|
13
13
 
14
14
  spec.summary = %q(pt-online-schema-change runner for ActiveRecord migrations)
15
15
  spec.description = %q(Execute your ActiveRecord migrations with Percona's pt-online-schema-change. Formerly known as Percona Migrator.)
16
- spec.homepage = 'https://github.com/departurerb/departure'
16
+ spec.homepage = 'https://github.com/austio/departure'
17
17
  spec.license = 'MIT'
18
18
 
19
19
  spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
@@ -1,10 +1,14 @@
1
1
  # This file was generated by Appraisal
2
2
 
3
- source 'https://rubygems.org'
3
+ source "https://rubygems.org"
4
4
 
5
- gem 'codeclimate-test-reporter', '~> 1.0.3', group: :test, require: nil
6
- gem 'rails', '6.1.7.6'
7
- gem 'rubocop', '~> 1.60.2', require: false
8
- gem 'rubocop-performance', '~> 1.20.2', require: false
5
+ gem "base64"
6
+ gem "codeclimate-test-reporter", "~> 1.0.3", group: :test, require: nil
7
+ gem "lhm"
8
+ gem "logger"
9
+ gem "mutex_m", require: false
10
+ gem "rubocop", "~> 1.74.0", require: false
11
+ gem "rubocop-performance", "~> 1.20.2", require: false
12
+ gem "rails", "6.1.7.6"
9
13
 
10
- gemspec path: '../'
14
+ gemspec path: "../"
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ..
3
3
  specs:
4
- departure (6.7.0)
4
+ departure (6.7.1.pre.2)
5
5
  activerecord (>= 6.0.0, < 7.3.0, != 7.0.0)
6
6
  mysql2 (>= 0.4.0, < 0.6.0)
7
7
  railties (>= 6.0.0, < 7.3.0, != 7.0.0)
@@ -1,10 +1,14 @@
1
1
  # This file was generated by Appraisal
2
2
 
3
- source 'https://rubygems.org'
3
+ source "https://rubygems.org"
4
4
 
5
- gem 'codeclimate-test-reporter', '~> 1.0.3', group: :test, require: nil
6
- gem 'rails', '7.0.8'
7
- gem 'rubocop', '~> 1.60.2', require: false
8
- gem 'rubocop-performance', '~> 1.20.2', require: false
5
+ gem "base64"
6
+ gem "codeclimate-test-reporter", "~> 1.0.3", group: :test, require: nil
7
+ gem "lhm"
8
+ gem "logger"
9
+ gem "mutex_m", require: false
10
+ gem "rubocop", "~> 1.74.0", require: false
11
+ gem "rubocop-performance", "~> 1.20.2", require: false
12
+ gem "rails", "7.0.8"
9
13
 
10
- gemspec path: '../'
14
+ gemspec path: "../"
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ..
3
3
  specs:
4
- departure (6.7.0)
4
+ departure (6.7.1.pre.2)
5
5
  activerecord (>= 6.0.0, < 7.3.0, != 7.0.0)
6
6
  mysql2 (>= 0.4.0, < 0.6.0)
7
7
  railties (>= 6.0.0, < 7.3.0, != 7.0.0)
@@ -1,10 +1,14 @@
1
1
  # This file was generated by Appraisal
2
2
 
3
- source 'https://rubygems.org'
3
+ source "https://rubygems.org"
4
4
 
5
- gem 'codeclimate-test-reporter', '~> 1.0.3', group: :test, require: nil
6
- gem 'rails', '7.1.3'
7
- gem 'rubocop', '~> 1.60.2', require: false
8
- gem 'rubocop-performance', '~> 1.20.2', require: false
5
+ gem "base64"
6
+ gem "codeclimate-test-reporter", "~> 1.0.3", group: :test, require: nil
7
+ gem "lhm"
8
+ gem "logger"
9
+ gem "mutex_m", require: false
10
+ gem "rubocop", "~> 1.74.0", require: false
11
+ gem "rubocop-performance", "~> 1.20.2", require: false
12
+ gem "rails", "7.1.3"
9
13
 
10
- gemspec path: '../'
14
+ gemspec path: "../"
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ..
3
3
  specs:
4
- departure (6.7.0)
4
+ departure (6.7.1.pre.2)
5
5
  activerecord (>= 6.0.0, < 7.3.0, != 7.0.0)
6
6
  mysql2 (>= 0.4.0, < 0.6.0)
7
7
  railties (>= 6.0.0, < 7.3.0, != 7.0.0)
@@ -114,7 +114,8 @@ GEM
114
114
  rdoc (>= 4.0.0)
115
115
  reline (>= 0.4.2)
116
116
  json (2.7.2)
117
- language_server-protocol (3.17.0.3)
117
+ language_server-protocol (3.17.0.4)
118
+ lint_roller (1.1.0)
118
119
  loofah (2.22.0)
119
120
  crass (~> 1.0.2)
120
121
  nokogiri (>= 1.12.0)
@@ -143,7 +144,7 @@ GEM
143
144
  racc (~> 1.4)
144
145
  nokogiri (1.18.3-x86_64-linux-gnu)
145
146
  racc (~> 1.4)
146
- parallel (1.25.1)
147
+ parallel (1.26.3)
147
148
  parser (3.3.3.0)
148
149
  ast (~> 2.4.1)
149
150
  racc
@@ -195,13 +196,11 @@ GEM
195
196
  zeitwerk (~> 2.6)
196
197
  rainbow (3.1.1)
197
198
  rake (13.2.1)
198
- rdoc (6.7.0)
199
+ rdoc (6.7.1.pre.2)
199
200
  psych (>= 4.0.0)
200
- regexp_parser (2.9.2)
201
+ regexp_parser (2.10.0)
201
202
  reline (0.5.9)
202
203
  io-console (~> 0.5)
203
- rexml (3.3.0)
204
- strscan
205
204
  rspec (3.13.0)
206
205
  rspec-core (~> 3.13.0)
207
206
  rspec-expectations (~> 3.13.0)
@@ -218,18 +217,18 @@ GEM
218
217
  diff-lcs (>= 1.2.0, < 2.0)
219
218
  rspec-support (~> 3.13.0)
220
219
  rspec-support (3.13.1)
221
- rubocop (1.60.2)
220
+ rubocop (1.74.0)
222
221
  json (~> 2.3)
223
- language_server-protocol (>= 3.17.0)
222
+ language_server-protocol (~> 3.17.0.2)
223
+ lint_roller (~> 1.1.0)
224
224
  parallel (~> 1.10)
225
225
  parser (>= 3.3.0.2)
226
226
  rainbow (>= 2.2.2, < 4.0)
227
- regexp_parser (>= 1.8, < 3.0)
228
- rexml (>= 3.2.5, < 4.0)
229
- rubocop-ast (>= 1.30.0, < 2.0)
227
+ regexp_parser (>= 2.9.3, < 3.0)
228
+ rubocop-ast (>= 1.38.0, < 2.0)
230
229
  ruby-progressbar (~> 1.7)
231
- unicode-display_width (>= 2.4.0, < 3.0)
232
- rubocop-ast (1.31.3)
230
+ unicode-display_width (>= 2.4.0, < 4.0)
231
+ rubocop-ast (1.39.0)
233
232
  parser (>= 3.3.1.0)
234
233
  rubocop-performance (1.20.2)
235
234
  rubocop (>= 1.48.1, < 2.0)
@@ -241,12 +240,13 @@ GEM
241
240
  simplecov-html (~> 0.10.0)
242
241
  simplecov-html (0.10.2)
243
242
  stringio (3.1.1)
244
- strscan (3.1.0)
245
243
  thor (1.3.1)
246
244
  timeout (0.4.1)
247
245
  tzinfo (2.0.6)
248
246
  concurrent-ruby (~> 1.0)
249
- unicode-display_width (2.5.0)
247
+ unicode-display_width (3.1.4)
248
+ unicode-emoji (~> 4.0, >= 4.0.4)
249
+ unicode-emoji (4.0.4)
250
250
  webrick (1.8.1)
251
251
  websocket-driver (0.7.6)
252
252
  websocket-extensions (>= 0.1.0)
@@ -267,7 +267,7 @@ DEPENDENCIES
267
267
  rake (>= 10.0)
268
268
  rspec (~> 3.4, >= 3.4.0)
269
269
  rspec-its (~> 1.2)
270
- rubocop (~> 1.60.2)
270
+ rubocop (~> 1.74.0)
271
271
  rubocop-performance (~> 1.20.2)
272
272
 
273
273
  BUNDLED WITH
@@ -1,10 +1,14 @@
1
1
  # This file was generated by Appraisal
2
2
 
3
- source 'https://rubygems.org'
3
+ source "https://rubygems.org"
4
4
 
5
- gem 'codeclimate-test-reporter', '~> 1.0.3', group: :test, require: nil
6
- gem 'rails', '7.2.2.1'
7
- gem 'rubocop', '~> 1.60.2', require: false
8
- gem 'rubocop-performance', '~> 1.20.2', require: false
5
+ gem "base64"
6
+ gem "codeclimate-test-reporter", "~> 1.0.3", group: :test, require: nil
7
+ gem "lhm"
8
+ gem "logger"
9
+ gem "mutex_m", require: false
10
+ gem "rubocop", "~> 1.74.0", require: false
11
+ gem "rubocop-performance", "~> 1.20.2", require: false
12
+ gem "rails", "7.2.2.1"
9
13
 
10
- gemspec path: '../'
14
+ gemspec path: "../"
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ..
3
3
  specs:
4
- departure (6.7.0)
4
+ departure (6.7.1.pre.2)
5
5
  activerecord (>= 6.0.0, < 7.3.0, != 7.0.0)
6
6
  mysql2 (>= 0.4.0, < 0.6.0)
7
7
  railties (>= 6.0.0, < 7.3.0, != 7.0.0)
@@ -114,6 +114,7 @@ GEM
114
114
  reline (>= 0.4.2)
115
115
  json (2.10.1)
116
116
  language_server-protocol (3.17.0.4)
117
+ lint_roller (1.1.0)
117
118
  logger (1.6.6)
118
119
  loofah (2.24.0)
119
120
  crass (~> 1.0.2)
@@ -201,7 +202,6 @@ GEM
201
202
  regexp_parser (2.10.0)
202
203
  reline (0.6.0)
203
204
  io-console (~> 0.5)
204
- rexml (3.4.1)
205
205
  rspec (3.13.0)
206
206
  rspec-core (~> 3.13.0)
207
207
  rspec-expectations (~> 3.13.0)
@@ -218,17 +218,17 @@ GEM
218
218
  diff-lcs (>= 1.2.0, < 2.0)
219
219
  rspec-support (~> 3.13.0)
220
220
  rspec-support (3.13.2)
221
- rubocop (1.60.2)
221
+ rubocop (1.74.0)
222
222
  json (~> 2.3)
223
- language_server-protocol (>= 3.17.0)
223
+ language_server-protocol (~> 3.17.0.2)
224
+ lint_roller (~> 1.1.0)
224
225
  parallel (~> 1.10)
225
226
  parser (>= 3.3.0.2)
226
227
  rainbow (>= 2.2.2, < 4.0)
227
- regexp_parser (>= 1.8, < 3.0)
228
- rexml (>= 3.2.5, < 4.0)
229
- rubocop-ast (>= 1.30.0, < 2.0)
228
+ regexp_parser (>= 2.9.3, < 3.0)
229
+ rubocop-ast (>= 1.38.0, < 2.0)
230
230
  ruby-progressbar (~> 1.7)
231
- unicode-display_width (>= 2.4.0, < 3.0)
231
+ unicode-display_width (>= 2.4.0, < 4.0)
232
232
  rubocop-ast (1.38.1)
233
233
  parser (>= 3.3.1.0)
234
234
  rubocop-performance (1.20.2)
@@ -246,7 +246,9 @@ GEM
246
246
  timeout (0.4.3)
247
247
  tzinfo (2.0.6)
248
248
  concurrent-ruby (~> 1.0)
249
- unicode-display_width (2.6.0)
249
+ unicode-display_width (3.1.4)
250
+ unicode-emoji (~> 4.0, >= 4.0.4)
251
+ unicode-emoji (4.0.4)
250
252
  useragent (0.16.11)
251
253
  websocket-driver (0.7.7)
252
254
  base64
@@ -267,7 +269,7 @@ DEPENDENCIES
267
269
  rake (>= 10.0)
268
270
  rspec (~> 3.4, >= 3.4.0)
269
271
  rspec-its (~> 1.2)
270
- rubocop (~> 1.60.2)
272
+ rubocop (~> 1.74.0)
271
273
  rubocop-performance (~> 1.20.2)
272
274
 
273
275
  BUNDLED WITH
@@ -5,7 +5,6 @@ require 'active_record/connection_adapters/patch_connection_handling'
5
5
  require 'active_support/core_ext/string/filters'
6
6
  require 'departure'
7
7
  require 'forwardable'
8
- require_relative './patch_connection_handling'
9
8
 
10
9
  module ActiveRecord
11
10
  module ConnectionAdapters
@@ -110,11 +110,9 @@ module ActiveRecord
110
110
  true
111
111
  end
112
112
 
113
- # rubocop:disable Metrics/ParameterLists
114
- def new_column(field, default, type_metadata, null, table_name, default_function, collation, comment)
115
- Column.new(field, default, type_metadata, null, table_name, default_function, collation, comment)
113
+ def new_column(...)
114
+ Column.new(...)
116
115
  end
117
- # rubocop:enable Metrics/ParameterLists
118
116
 
119
117
  # Adds a new index to the table
120
118
  #
@@ -186,7 +184,6 @@ module ActiveRecord
186
184
  with_raw_connection(allow_retry: allow_retry, materialize_transactions: materialize_transactions) do |conn|
187
185
  sync_timezone_changes(conn)
188
186
  result = conn.query(sql)
189
- # conn.abandon_results!
190
187
  verified! if allow_retry
191
188
  handle_warnings(sql)
192
189
  if result.is_a? Process::Status
@@ -42,7 +42,7 @@ module Departure
42
42
  # execution status
43
43
  def run_in_process
44
44
  Open3.popen3(full_command) do |_stdin, stdout, _stderr, waith_thr|
45
- begin
45
+ begin # rubocop:disable Style/RedundantBegin
46
46
  loop do
47
47
  IO.select([stdout])
48
48
  data = stdout.read_nonblock(8192)
@@ -1,6 +1,7 @@
1
1
  module Departure
2
2
  class Configuration
3
- attr_accessor :tmp_path, :global_percona_args, :enabled_by_default, :redirect_stderr
3
+ attr_accessor :tmp_path, :global_percona_args, :enabled_by_default, :redirect_stderr,
4
+ :disable_rails_advisory_lock_patch
4
5
 
5
6
  def initialize
6
7
  @tmp_path = '.'.freeze
@@ -31,6 +31,12 @@ module Departure
31
31
  ActiveRecord::Migration.class_eval do
32
32
  include Departure::Migration
33
33
  end
34
+
35
+ if ActiveRecord::VERSION::MAJOR == 7 && ActiveRecord::VERSION::MINOR == 1
36
+ require 'departure/rails_patches/active_record_migrator_with_advisory_lock_patch'
37
+
38
+ ActiveRecord::Migrator.prepend Departure::RailsPatches::ActiveRecordMigratorWithAdvisoryLockPatch
39
+ end
34
40
  end
35
41
  end
36
42
 
@@ -72,11 +78,14 @@ module Departure
72
78
  class << self
73
79
  def register_integrations
74
80
  require 'active_record/connection_adapters/rails_7_2_departure_adapter'
81
+ require 'departure/rails_patches/active_record_migrator_with_advisory_lock_patch'
75
82
 
76
83
  ActiveSupport.on_load(:active_record) do
77
84
  ActiveRecord::Migration.class_eval do
78
85
  include Departure::Migration
79
86
  end
87
+
88
+ ActiveRecord::Migrator.prepend Departure::RailsPatches::ActiveRecordMigratorWithAdvisoryLockPatch
80
89
  end
81
90
 
82
91
  ActiveRecord::ConnectionAdapters.register 'percona',
@@ -0,0 +1,25 @@
1
+ module Departure
2
+ module RailsPatches
3
+ module ActiveRecordMigratorWithAdvisoryLockPatch
4
+ RELEASE_LOCK_FAILED_MESSAGE = 'Failed to release advisory lock from ActiveRecordMigratorWithAdvisoryLockPatch'
5
+ .freeze
6
+
7
+ def with_advisory_lock
8
+ return super if Departure.configuration.disable_rails_advisory_lock_patch
9
+
10
+ lock_id = generate_migrator_advisory_lock_id
11
+ @__original_connection = connection
12
+
13
+ got_lock = @__original_connection.get_advisory_lock(lock_id)
14
+ raise ConcurrentMigrationError unless got_lock
15
+
16
+ load_migrated # reload schema_migrations to be sure it wasn't changed by another process before we got the lock
17
+ yield
18
+ ensure
19
+ if got_lock && !@__original_connection.release_advisory_lock(lock_id)
20
+ raise ConcurrentMigrationError, RELEASE_LOCK_FAILED_MESSAGE
21
+ end
22
+ end
23
+ end
24
+ end
25
+ end
@@ -1,3 +1,3 @@
1
1
  module Departure
2
- VERSION = '6.7.1-pre'.freeze
2
+ VERSION = '6.7.1.pre.2'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: departure-next
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.7.1.pre.pre
4
+ version: 6.7.1.pre.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ilya Zayats
@@ -15,7 +15,7 @@ authors:
15
15
  autorequire:
16
16
  bindir: bin
17
17
  cert_chain: []
18
- date: 2025-03-14 00:00:00.000000000 Z
18
+ date: 2025-03-28 00:00:00.000000000 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: railties
@@ -200,7 +200,6 @@ files:
200
200
  - ".rspec"
201
201
  - ".rubocop.yml"
202
202
  - ".rubocop_todo.yml"
203
- - 20250312235906_add_deleted_reason_to_newsfeed_activities.rb
204
203
  - Appraisals
205
204
  - CHANGELOG.md
206
205
  - CODE_OF_CONDUCT.md
@@ -217,7 +216,7 @@ files:
217
216
  - bin/setup
218
217
  - config.yml.erb
219
218
  - configuration.rb
220
- - departure-next.gemspec
219
+ - departure.gemspec
221
220
  - docker-compose.yml
222
221
  - gemfiles/rails_6_1.gemfile
223
222
  - gemfiles/rails_6_1.gemfile.lock
@@ -247,6 +246,7 @@ files:
247
246
  - lib/departure/null_logger.rb
248
247
  - lib/departure/option.rb
249
248
  - lib/departure/rails_adapter.rb
249
+ - lib/departure/rails_patches/active_record_migrator_with_advisory_lock_patch.rb
250
250
  - lib/departure/railtie.rb
251
251
  - lib/departure/runner.rb
252
252
  - lib/departure/user_options.rb
@@ -256,7 +256,7 @@ files:
256
256
  - lib/lhm/column_with_sql.rb
257
257
  - lib/lhm/column_with_type.rb
258
258
  - test_database.rb
259
- homepage: https://github.com/departurerb/departure
259
+ homepage: https://github.com/austio/departure
260
260
  licenses:
261
261
  - MIT
262
262
  metadata: {}
@@ -271,11 +271,11 @@ required_ruby_version: !ruby/object:Gem::Requirement
271
271
  version: 2.7.0
272
272
  required_rubygems_version: !ruby/object:Gem::Requirement
273
273
  requirements:
274
- - - ">"
274
+ - - ">="
275
275
  - !ruby/object:Gem::Version
276
- version: 1.3.1
276
+ version: '0'
277
277
  requirements: []
278
- rubygems_version: 3.4.19
278
+ rubygems_version: 3.5.22
279
279
  signing_key:
280
280
  specification_version: 4
281
281
  summary: pt-online-schema-change runner for ActiveRecord migrations
@@ -1,5 +0,0 @@
1
- class AddDeletedReasonToNewsfeedActivities < ActiveRecord::Migration[7.1]
2
- def change
3
- add_column :newsfeed_activities, :some_deleted_reason, :string
4
- end
5
- end