Skip to content

Commit

Permalink
Merge pull request #80 from viralpraxis/add-rails-7-2-support
Browse files Browse the repository at this point in the history
Add rails `7.2` support
  • Loading branch information
sharshenov authored Aug 13, 2024
2 parents 179184f + 63aa87c commit e376253
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 3 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ jobs:
- gemfiles/activejob_6.1.x.gemfile
- gemfiles/activejob_7.0.x.gemfile
- gemfiles/activejob_7.1.x.gemfile
- gemfiles/activejob_7.2.x.gemfile
- gemfiles/sidekiq_4.x.gemfile
- gemfiles/sidekiq_5.x.gemfile
- gemfiles/sidekiq_6.x.gemfile
Expand All @@ -42,6 +43,8 @@ jobs:
gemfile: gemfiles/activejob_7.0.x.gemfile
- ruby: 2.5.9
gemfile: gemfiles/activejob_7.1.x.gemfile
- ruby: 2.5.9
gemfile: gemfiles/activejob_7.2.x.gemfile
- ruby: 2.5.9
gemfile: gemfiles/sidekiq_6.x.gemfile
- ruby: 2.5.9
Expand All @@ -50,18 +53,24 @@ jobs:
gemfile: gemfiles/activejob_7.0.x.gemfile
- ruby: 2.6.10
gemfile: gemfiles/activejob_7.1.x.gemfile
- ruby: 2.6.10
gemfile: gemfiles/activejob_7.2.x.gemfile
- ruby: 2.6.10
gemfile: gemfiles/sidekiq_6.x.gemfile
- ruby: 2.6.10
gemfile: gemfiles/sidekiq_7.x.gemfile
- ruby: 2.7.7
gemfile: gemfiles/activejob_4.2.x.gemfile
- ruby: 2.7.7
gemfile: gemfiles/activejob_7.2.x.gemfile
- ruby: 2.7.7
gemfile: gemfiles/sidekiq_4.x.gemfile
- ruby: 3.0.5
gemfile: gemfiles/activejob_4.2.x.gemfile
- ruby: 3.0.5
gemfile: gemfiles/activejob_5.2.x.gemfile
- ruby: 3.0.5
gemfile: gemfiles/activejob_7.2.x.gemfile
- ruby: 3.0.5
gemfile: gemfiles/sidekiq_4.x.gemfile
- ruby: 3.0.5
Expand Down
4 changes: 4 additions & 0 deletions Appraisals
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ appraise 'activejob-7.1.x' do
gem 'activejob', '~> 7.1'
end

appraise 'activejob-7.2.x' do
gem 'activejob', '~> 7.2'
end

appraise 'sidekiq-4.x' do
gem 'sidekiq', '~> 4.2'
gem 'activejob', '~> 5.2'
Expand Down
2 changes: 1 addition & 1 deletion activejob-uniqueness.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Gem::Specification.new do |spec|

spec.required_ruby_version = '>= 2.5'

spec.add_dependency 'activejob', '>= 4.2', '< 7.2'
spec.add_dependency 'activejob', '>= 4.2', '< 7.3'
spec.add_dependency 'redlock', '>= 2.0', '< 3'

spec.add_development_dependency 'appraisal', '~> 2.3.0'
Expand Down
7 changes: 7 additions & 0 deletions gemfiles/activejob_7.2.x.gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# This file was generated by Appraisal

source "https://rubygems.org"

gem "activejob", "~> 7.2"

gemspec path: "../"
4 changes: 2 additions & 2 deletions lib/active_job/uniqueness/sidekiq_patch.rb
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def remove_job
module ScheduledSet
def delete(score, job_id)
entry = find_job(job_id)
ActiveJob::Uniqueness.unlock_sidekiq_job!(entry.item) if super(score, job_id)
ActiveJob::Uniqueness.unlock_sidekiq_job!(entry.item) if super
entry
end
end
Expand All @@ -67,7 +67,7 @@ def clear
end

def delete_by_value(name, value)
ActiveJob::Uniqueness.unlock_sidekiq_job!(Sidekiq.load_json(value)) if super(name, value)
ActiveJob::Uniqueness.unlock_sidekiq_job!(Sidekiq.load_json(value)) if super
end
end
end
Expand Down

0 comments on commit e376253

Please sign in to comment.