feat: replace rails dependency with specific components - #69
Merged
Conversation
andrewdt23
approved these changes
Aug 17, 2026
Replace the monolithic `rails` gem dependency with only the specific Rails components actually used: actionpack, activerecord, activesupport, and railties. This reduces the transitive dependency footprint for consumers that don't need the full Rails framework.
Maimer
force-pushed
the
pim_remove_explicit_rails_dependency
branch
from
August 18, 2026 18:23
2bffe4d to
b2b1f55
Compare
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.
Summary
Replace the monolithic
railsgem dependency with only the specific Rails components actually used by the gem:actionpack,activerecord,activesupport, andrailties. This reduces the transitive dependency footprint for consumers that don't need the full Rails framework.The gem uses
ActionController::Base(actionpack),ActiveRecord::Base/ActiveRecord::Relation(activerecord),ActiveSupport::OrderedHash/ActiveSupport::Concern(activesupport), andRails::Engine/Rails::Generators::Base(railties). The tworequire 'rails'statements in lib/ are replaced with targeted requires (rails/railtieandrails/engine).Jira Issue: https://appfolio.atlassian.net/browse/BANK-2196
Test plan
bundle installsucceeds with the updated gemspecbundle exec appraisal installsucceeds for all 18 appraisal combinationsbundle exec appraisal rake testpasses across all 18 matrices (Rails 7.2/8.0/8.1 x Grape 1.6-2.2) with 224 tests, 524 assertions, 0 failures, 0 errors per run