Skip to content

Replace deprecated ActiveSupport::Configurable with explicit Configuration class#4

Merged
nerlichman merged 3 commits intogogrow-dev:mainfrom
mepatterson:fix/deprecate-activesupport-configurable
Feb 23, 2026
Merged

Replace deprecated ActiveSupport::Configurable with explicit Configuration class#4
nerlichman merged 3 commits intogogrow-dev:mainfrom
mepatterson:fix/deprecate-activesupport-configurable

Conversation

@mepatterson
Copy link
Contributor

@mepatterson mepatterson commented Feb 23, 2026

ActiveSupport::Configurable was deprecated in Rails 8.1 and will be removed in Rails 8.2.

This replaces it with an explicit Configuration class, which is the standard pattern for Ruby gems.

Changes:

  • Add Mailcat::Configuration class with attr_accessor for mailcat_api_key and mailcat_url
  • ENV defaults are set in Configuration#initialize
  • Add Mailcat.config and Mailcat.configure class methods
  • Update DeliveryMethod to use Mailcat.config.* instead of Mailcat.*_raw
  • Drop active_support/core_ext/module/attribute_accessors require (no longer needed)

The public configure API is unchanged:

Mailcat.configure do |config|
  config.mailcat_api_key = "..."
  config.mailcat_url = "..."
end

@mepatterson mepatterson changed the title Replace deprecated ActiveSupport::Configurable with mattr_accessor Replace deprecated ActiveSupport::Configurable with explicit Configuration class Feb 23, 2026
@nerlichman nerlichman merged commit f54cda0 into gogrow-dev:main Feb 23, 2026
1 check passed
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.

2 participants