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

Add lockfile #32

Merged
merged 2 commits into from
Jan 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
.DS_Store
.rvmrc
/coverage
Gemfile.lock
gemfiles/*.lock
Copy link
Contributor Author

@Irving-Betterment Irving-Betterment Jan 5, 2024

Choose a reason for hiding this comment

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

I kept appraisal lockfiles ignored because with the current Ruby version support bracket (2.6 ... 3.2) some dependencies like nokogiri cannot be locked due not having enough broad support (1, 2). Therefore CI test matrix fails for some of these incompatible combinations.

Copy link
Member

Choose a reason for hiding this comment

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

I'm not sure we get much of the benefits without this, but I'm approving this PR because at least the primary gemfile will allow for a consistent experience for someone who pulls down the repo.

Copy link
Contributor Author

@Irving-Betterment Irving-Betterment Jan 8, 2024

Choose a reason for hiding this comment

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

@smudge indeed, starting with rubocop (lint job) not drifting due new cops available on each release (like the one I had to adjust myself here).

pkg/*
*.sqlite
3 changes: 3 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,6 @@ AllCops:

Rails/EnvironmentVariableAccess:
Enabled: false

RSpec/IndexedLet:
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Rubocop started to lint this cop, which I disabled as spec subjects have this pattern.

Enabled: false
129 changes: 129 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,129 @@
PATH
remote: .
specs:
delayed (0.5.2)
activerecord (>= 5.2)
concurrent-ruby

GEM
remote: https://rubygems.org/
specs:
actionmailer (0.6.1)
actionpack (>= 0.9.5)
actionpack (1.4.0)
activejob (6.1.7.6)
activesupport (= 6.1.7.6)
globalid (>= 0.3.6)
activemodel (6.1.7.6)
activesupport (= 6.1.7.6)
activerecord (6.1.7.6)
activemodel (= 6.1.7.6)
activesupport (= 6.1.7.6)
activesupport (6.1.7.6)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 1.6, < 2)
minitest (>= 5.1)
tzinfo (~> 2.0)
zeitwerk (~> 2.3)
appraisal (2.5.0)
bundler
rake
thor (>= 0.14.0)
ast (2.4.2)
betterlint (1.4.4)
rubocop (> 1.0)
rubocop-performance
rubocop-rails
rubocop-rake
rubocop-rspec (>= 2.7)
concurrent-ruby (1.2.2)
diff-lcs (1.5.0)
globalid (1.2.1)
activesupport (>= 6.1)
i18n (1.14.1)
concurrent-ruby (~> 1.0)
json (2.7.1)
minitest (5.20.0)
mysql2 (0.5.5)
parallel (1.24.0)
parser (3.3.0.0)
ast (~> 2.4.1)
racc
pg (1.5.4)
racc (1.7.3)
rack (3.0.8)
rainbow (3.1.1)
rake (13.1.0)
regexp_parser (2.8.3)
rexml (3.2.6)
rspec (3.12.0)
rspec-core (~> 3.12.0)
rspec-expectations (~> 3.12.0)
rspec-mocks (~> 3.12.0)
rspec-core (3.12.2)
rspec-support (~> 3.12.0)
rspec-expectations (3.12.3)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.12.0)
rspec-mocks (3.12.6)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.12.0)
rspec-support (3.12.1)
rubocop (1.50.2)
json (~> 2.3)
parallel (~> 1.10)
parser (>= 3.2.0.0)
rainbow (>= 2.2.2, < 4.0)
regexp_parser (>= 1.8, < 3.0)
rexml (>= 3.2.5, < 4.0)
rubocop-ast (>= 1.28.0, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
rubocop-ast (1.30.0)
parser (>= 3.2.1.0)
rubocop-capybara (2.18.0)
rubocop (~> 1.41)
rubocop-performance (1.17.1)
rubocop (>= 1.7.0, < 2.0)
rubocop-ast (>= 0.4.0)
rubocop-rails (2.19.1)
activesupport (>= 4.2.0)
rack (>= 1.1)
rubocop (>= 1.33.0, < 2.0)
rubocop-rake (0.6.0)
rubocop (~> 1.0)
rubocop-rspec (2.20.0)
rubocop (~> 1.33)
rubocop-capybara (~> 2.17)
ruby-progressbar (1.13.0)
sqlite3 (1.6.9-x86_64-darwin)
sqlite3 (1.6.9-x86_64-linux)
thor (1.3.0)
timecop (0.9.8)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unicode-display_width (2.5.0)
zeitwerk (2.6.12)

PLATFORMS
x86_64-darwin-21
x86_64-darwin-22
x86_64-linux

DEPENDENCIES
actionmailer
activejob
activerecord
appraisal
betterlint
delayed!
mysql2
pg
rake
rspec
sqlite3
timecop
zeitwerk

BUNDLED WITH
2.4.13
2 changes: 1 addition & 1 deletion lib/delayed/monitor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def run!
attr_reader :jobs

def emit_metric!(metric)
send("#{metric}_grouped").reverse_merge(default_results).each do |(priority, queue), value|
send(:"#{metric}_grouped").reverse_merge(default_results).each do |(priority, queue), value|
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Address rubocop offense that cropped up.

ActiveSupport::Notifications.instrument(
"delayed.job.#{metric}",
default_tags.merge(priority: Priority.new(priority).to_s, queue: queue, value: value),
Expand Down
Loading