Drop the unused rubocop-packs dependency - #76
Merged
joemsak merged 1 commit intoSep 30, 2026
Merged
Conversation
PackwerkCheckerUsage requires rubocop-packs but uses nothing from it: it only tallies enforce_* keys read from package.yml. The require is left over from the package_protections removal (rubyatscale#21), and it made every consumer install rubocop-packs and load RuboCop at runtime. Removes the require, the gemspec dependency, the tapioca require and the gem RBI, and bumps to 0.2.2 so the change publishes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
joemsak
approved these changes
Sep 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
lib/pack_stats/private/metrics/packwerk_checker_usage.rbdoesrequire "rubocop-packs"but never uses anything from it. The class only readsenforce_*keys from eachpackage.ymland tallies them. The require is left over from dropping package_protections (#21).Because of it, every app that installs
pack_statsalso getsrubocop-packsin its bundle and loads RuboCop at runtime. Gusto/zenpayroll has turned off everyPacks/*andPackwerkLite/*cop and is removing its ownrubocop-packsdependency, and this require is the only thing keeping the gem in its bundle.What changes
packwerk_checker_usage.rband fromsorbet/tapioca/require.rbrubocop-packsfrom the gemspec's runtime dependencies. The lockfile change is pruning only: every transitive dependency ofrubocop-packsis still required by something else.sorbet/rbi/gems/rubocop-packs@0.0.45.rbiVerification
These ran locally on Ruby 3.4.11, since 4.0.7 isn't installed on my machine. The gemspec allows
>= 3.3.bundle exec rspec: 19 examples, 0 failuresbundle exec srb tc: no errorsbundle exec rubocop: 20 files, no offensesrequire "pack_stats"loads withRuboCopleft undefinedUnrelated, found while checking this: the
"emits metrics about rubocop exclusions"example inspec/pack_stats/pack_stats_spec.rbhas an empty body. It's another leftover from the same removal, so I've left it for a separate cleanup.🤖 Generated with Claude Code