Skip to content

fix: use judge parameter in repeatedly log#465

Merged
yegor256 merged 1 commit into
zerocracy:masterfrom
GHX5T-SOL:fix/464-repeatedly-judge-log
May 25, 2026
Merged

fix: use judge parameter in repeatedly log#465
yegor256 merged 1 commit into
zerocracy:masterfrom
GHX5T-SOL:fix/464-repeatedly-judge-log

Conversation

@GHX5T-SOL
Copy link
Copy Markdown
Contributor

Summary

  • use the judge: parameter in the Fbe.repeatedly skip log instead of the $judge global
  • add regression coverage for the parameter/global mismatch

Closes #464.

Validation

  • bundle exec ruby test/fbe/test_repeatedly.rb (2 tests, 6 assertions, 0 failures)
  • bundle exec rake test (274 tests, 774 assertions, 0 failures, 9 skips)
  • bundle exec rake rubocop (65 files inspected, no offenses)
  • bundle exec rake yard (completed, 81.82% documented)
  • bundle exec rake picks (exited 0)
  • git diff --check HEAD~1 HEAD (passed)
  • git show --format= --patch HEAD | gitleaks stdin --no-banner --redact --timeout 30 (no leaks found)

Notes

  • Local validation used Homebrew portable Ruby 4.0.3 because the system Ruby is 2.6.10.
  • The test runs emit Ruby 4/Bundler constant redefinition warnings and existing award.rb future frozen string warnings, but the commands above exited 0.

Copy link
Copy Markdown
Contributor

@edmoffo edmoffo left a comment

Choose a reason for hiding this comment

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

The one-line change in lib/fbe/repeatedly.rb and the regression test in test/fbe/test_repeatedly.rb cover the parameter/global mismatch on the skip-log line. CI is green.

Copy link
Copy Markdown
Contributor

@bibonix bibonix left a comment

Choose a reason for hiding this comment

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

The one-line change in lib/fbe/repeatedly.rb line 48 replaces the $judge global with the judge parameter in the skip-log message, which matches the fix described in #464 and aligns the log line with how the rest of the method already uses the parameter. The new test_log_uses_judge_parameter_not_global test sets the global and the parameter to different values and asserts the parameter wins, which pins the regression. CI is green across all jobs.

One leftover: the guard raise(Fbe::Error, 'The $judge is not set') if judge.nil? on line 39 still names the global, even though it now checks the parameter. Worth a follow-up on the message text, but not blocking this fix.

@0crat
Copy link
Copy Markdown

0crat commented May 20, 2026

@bibonix Thanks for the review! You've earned +6 points for this contribution: +18 as a basis, -8 for absolutely no comments posted, and -4 for too few (22) hits-of-code. Your running score is +406; don't forget to check your Zerocracy account too.

@0crat
Copy link
Copy Markdown

0crat commented May 20, 2026

@edmoffo Thanks for the review! You've earned +6 points for this contribution: +18 as the base reward, -8 for no comments posted during review, and -4 for having fewer than 24 hits-of-code (22 total). Your running score is +76; don't forget to check your Zerocracy account too.

@yegor256 yegor256 merged commit 100e9b4 into zerocracy:master May 25, 2026
10 checks passed
@0crat
Copy link
Copy Markdown

0crat commented May 26, 2026

@GHX5T-SOL Hey! Nice work on your contribution! 🎉 You scored +20 points this time: started with the standard +24 base points, but lost 4 points since your 22 hits-of-code was under our 30 minimum. To max out your bonus next time, aim for that sweet spot of 30-133 hits-of-code and make sure to get some code reviews - our policy rewards quality contributions that hit these targets! Keep the awesome work coming. Your running score is +32 - don't forget to check your Zerocracy account too!

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.

repeatedly.rb log uses $judge global instead of the judge parameter

5 participants