actionmailer 7.1.5.1 → 7.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 65ca25381119a735258d9cbda82ec18416f4043fa4341a551ef381046bbc5f9a
4
- data.tar.gz: 056e9bd91385999a64786d99b2eabc9a2352dbf0f393b8b1cd8e2bb40d1d9178
3
+ metadata.gz: ea95f7b9ad1d651201aa13e40109d61ab1403758f1765d567d8e76451b4d3b6a
4
+ data.tar.gz: b4818f516ae894b13d0987b8e6fd0f0230372520cd41c1f5a7018cf2ee4a2e22
5
5
  SHA512:
6
- metadata.gz: b9d722ac033c8727a8cb776bd886eb350f1e8cbe8627e784a1d60cbbd8147cefcbdd00ec74b7f80b12482361c55cac13248fcd6b48ecf2b1b29a722a1bb73c01
7
- data.tar.gz: 86ae2eb8489c31c1428c0698715ab7819f8974c96ea16fb28d04156e78fc1cccfb79c8482ece17a4a2828c0f5f083f6b67c026b7bc809351dbf3cb6d6a31abb3
6
+ metadata.gz: 8f62423584f6958284713572300ef0fbd90ab2a9ff80778fe4063c283d348ce38e481bb3a2817e02ed508050dd792ea438f00f9b8ea1830fe0a85997d9fe7fbc
7
+ data.tar.gz: ec7a1e310e44cf49424ec0dd3adb81486f0811ec8d5078d44352fbecde3c1417342681bbba91a1d4ce232ec18661c5feaa02eb412c508a5f6c786161b5968350
data/CHANGELOG.md CHANGED
@@ -1,209 +1,52 @@
1
- ## Rails 7.1.5.1 (December 10, 2024) ##
1
+ ## Rails 7.2.3 (October 28, 2025) ##
2
2
 
3
3
  * No changes.
4
4
 
5
5
 
6
- ## Rails 7.1.5 (October 30, 2024) ##
6
+ ## Rails 7.2.2.2 (August 13, 2025) ##
7
7
 
8
8
  * No changes.
9
9
 
10
10
 
11
- ## Rails 7.1.4.2 (October 23, 2024) ##
12
-
13
- * Fix NoMethodError in `block_format` helper
14
-
15
- *Michael Leimstaedtner*
16
-
17
-
18
- ## Rails 7.1.4.1 (October 15, 2024) ##
19
-
20
- * Avoid regex backtracking in `block_format` helper
21
-
22
- [CVE-2024-47889]
23
-
24
- *John Hawthorn*
25
-
26
-
27
- ## Rails 7.1.4 (August 22, 2024) ##
28
-
29
- * No changes.
30
-
31
-
32
- ## Rails 7.1.3.4 (June 04, 2024) ##
33
-
34
- * No changes.
35
-
36
-
37
- ## Rails 7.1.3.3 (May 16, 2024) ##
38
-
39
- * No changes.
40
-
41
-
42
- ## Rails 7.1.3.2 (February 21, 2024) ##
11
+ ## Rails 7.2.2.1 (December 10, 2024) ##
43
12
 
44
13
  * No changes.
45
14
 
46
15
 
47
- ## Rails 7.1.3.1 (February 21, 2024) ##
16
+ ## Rails 7.2.2 (October 30, 2024) ##
48
17
 
49
18
  * No changes.
50
19
 
51
20
 
52
- ## Rails 7.1.3 (January 16, 2024) ##
53
-
54
- * No changes.
55
-
21
+ ## Rails 7.2.1.2 (October 23, 2024) ##
56
22
 
57
- ## Rails 7.1.2 (November 10, 2023) ##
58
-
59
- * No changes.
23
+ * Fix NoMethodError in `block_format` helper
60
24
 
25
+ *Michael Leimstaedtner*
61
26
 
62
- ## Rails 7.1.1 (October 11, 2023) ##
63
27
 
64
- * No changes.
28
+ ## Rails 7.2.1.1 (October 15, 2024) ##
65
29
 
30
+ * Avoid regex backtracking in `block_format` helper
66
31
 
67
- ## Rails 7.1.0 (October 05, 2023) ##
32
+ [CVE-2024-47889]
68
33
 
69
- * No changes.
34
+ *John Hawthorn*
70
35
 
71
36
 
72
- ## Rails 7.1.0.rc2 (October 01, 2023) ##
37
+ ## Rails 7.2.1 (August 22, 2024) ##
73
38
 
74
39
  * No changes.
75
40
 
76
41
 
77
- ## Rails 7.1.0.rc1 (September 27, 2023) ##
78
-
79
- * Introduce `ActionMailer::FormBuilder`
80
-
81
- Use the `default_form_builder` method in mailers to set the default form builder
82
- for templates rendered by that mailer. Matches the behaviour in Action Controller.
83
-
84
- *Alex Ghiculescu*
85
-
86
-
87
- ## Rails 7.1.0.beta1 (September 13, 2023) ##
88
-
89
- * Mailers are listed in alphabetical order on the mailer preview page now.
90
-
91
- *Martin Spickermann*
92
-
93
- * Deprecate passing params to `assert_enqueued_email_with` via the `:args`
94
- kwarg. `assert_enqueued_email_with` now supports a `:params` kwarg, so use
95
- that to pass params:
96
-
97
- ```ruby
98
- # BEFORE
99
- assert_enqueued_email_with MyMailer, :my_method, args: { my_param: "value" }
100
-
101
- # AFTER
102
- assert_enqueued_email_with MyMailer, :my_method, params: { my_param: "value" }
103
- ```
104
-
105
- To specify named mailer args as a Hash, wrap the Hash in an array:
106
-
107
- ```ruby
108
- assert_enqueued_email_with MyMailer, :my_method, args: [{ my_arg: "value" }]
109
- # OR
110
- assert_enqueued_email_with MyMailer, :my_method, args: [my_arg: "value"]
111
- ```
112
-
113
- *Jonathan Hefner*
114
-
115
- * Accept procs for args and params in `assert_enqueued_email_with`
116
-
117
- ```ruby
118
- assert_enqueued_email_with DeliveryJob, params: -> p { p[:token] =~ /\w+/ } do
119
- UserMailer.with(token: user.generate_token).email_verification.deliver_later
120
- end
121
- ```
122
-
123
- *Max Chernyak*
124
-
125
- * Added `*_deliver` callbacks to `ActionMailer::Base` that wrap mail message delivery.
126
-
127
- Example:
128
-
129
- ```ruby
130
- class EventsMailer < ApplicationMailer
131
- after_deliver do
132
- User.find_by(email: message.to.first).update(email_provider_id: message.message_id, emailed_at: Time.current)
133
- end
134
- end
135
- ```
136
-
137
- *Ben Sheldon*
138
-
139
- * Added `deliver_enqueued_emails` to `ActionMailer::TestHelper`. This method
140
- delivers all enqueued email jobs.
141
-
142
- Example:
143
-
144
- ```ruby
145
- def test_deliver_enqueued_emails
146
- deliver_enqueued_emails do
147
- ContactMailer.welcome.deliver_later
148
- end
149
- assert_emails 1
150
- end
151
- ```
152
-
153
- *Andrew Novoselac*
154
-
155
- * The `deliver_later_queue_name` used by the default mailer job can now be
156
- configured on a per-mailer basis. Previously this was only configurable
157
- for all mailers via `ActionMailer::Base`.
158
-
159
- Example:
160
-
161
- ```ruby
162
- class EventsMailer < ApplicationMailer
163
- self.deliver_later_queue_name = :throttled_mailer
164
- end
165
- ```
166
-
167
- *Jeffrey Hardy*
168
-
169
- * Email previews now include an expandable section to show all headers.
170
-
171
- Headers like `Message-ID` for threading or email service provider specific
172
- features like analytics tags or account metadata can now be viewed directly
173
- in the mailer preview.
174
-
175
- *Matt Swanson*
176
-
177
- * Default `ActionMailer::Parameterized#params` to an empty `Hash`
178
-
179
- *Sean Doyle*
180
-
181
- * Introduce the `capture_emails` test helper.
182
-
183
- Returns all emails that are sent in a block.
184
-
185
- ```ruby
186
- def test_emails
187
- emails = capture_emails do
188
- ContactMailer.welcome.deliver_now
189
- ContactMailer.welcome.deliver_later
190
- end
191
- assert_email "Hi there", emails.first.subject
192
- end
193
- ```
194
-
195
- *Alex Ghiculescu*
196
-
197
- * Added ability to download `.eml` file for the email preview.
42
+ ## Rails 7.2.0 (August 09, 2024) ##
198
43
 
199
- *Igor Kasyanchuk*
44
+ * Remove deprecated params via `:args` for `assert_enqueued_email_with`.
200
45
 
201
- * Support multiple preview paths for mailers.
46
+ *Rafael Mendonça França*
202
47
 
203
- Option `config.action_mailer.preview_path` is deprecated in favor of
204
- `config.action_mailer.preview_paths`. Appending paths to this configuration option
205
- will cause those paths to be used in the search for mailer previews.
48
+ * Remove deprecated `config.action_mailer.preview_path`.
206
49
 
207
- *fatkodima*
50
+ *Rafael Mendonça França*
208
51
 
209
- Please check [7-0-stable](https://github.com/rails/rails/blob/7-0-stable/actionmailer/CHANGELOG.md) for previous changes.
52
+ Please check [7-1-stable](https://github.com/rails/rails/blob/7-1-stable/actionmailer/CHANGELOG.md) for previous changes.
data/README.rdoc CHANGED
@@ -136,6 +136,6 @@ Bug reports for the Ruby on \Rails project can be filed here:
136
136
 
137
137
  * https://github.com/rails/rails/issues
138
138
 
139
- Feature requests should be discussed on the rails-core mailing list here:
139
+ Feature requests should be discussed on the rubyonrails-core forum here:
140
140
 
141
141
  * https://discuss.rubyonrails.org/c/rubyonrails-core
@@ -574,18 +574,13 @@ module ActionMailer
574
574
  attr_writer :mailer_name
575
575
  alias :controller_path :mailer_name
576
576
 
577
- # Sets the defaults through app configuration:
578
- #
579
- # config.action_mailer.default(from: "no-reply@example.org")
577
+ # Allows to set defaults through app configuration:
580
578
  #
581
- # Aliased by ::default_options=
579
+ # config.action_mailer.default_options = { from: "no-reply@example.org" }
582
580
  def default(value = nil)
583
581
  self.default_params = default_params.merge(value).freeze if value
584
582
  default_params
585
583
  end
586
- # Allows to set defaults through app configuration:
587
- #
588
- # config.action_mailer.default_options = { from: "no-reply@example.org" }
589
584
  alias :default_options= :default
590
585
 
591
586
  # Wraps an email delivery inside of ActiveSupport::Notifications instrumentation.
@@ -625,17 +620,16 @@ module ActionMailer
625
620
  payload[:perform_deliveries] = mail.perform_deliveries
626
621
  end
627
622
 
628
- def method_missing(method_name, *args)
629
- if action_methods.include?(method_name.to_s)
630
- MessageDelivery.new(self, method_name, *args)
623
+ def method_missing(method_name, ...)
624
+ if action_methods.include?(method_name.name)
625
+ MessageDelivery.new(self, method_name, ...)
631
626
  else
632
627
  super
633
628
  end
634
629
  end
635
- ruby2_keywords(:method_missing)
636
630
 
637
631
  def respond_to_missing?(method, include_all = false)
638
- action_methods.include?(method.to_s) || super
632
+ action_methods.include?(method.name) || super
639
633
  end
640
634
  end
641
635
 
@@ -669,7 +663,7 @@ module ActionMailer
669
663
  true
670
664
  end
671
665
 
672
- def method_missing(*args)
666
+ def method_missing(...)
673
667
  nil
674
668
  end
675
669
  end
@@ -32,8 +32,7 @@ module ActionMailer
32
32
 
33
33
  add_delivery_method :sendmail, Mail::Sendmail,
34
34
  location: "/usr/sbin/sendmail",
35
- # See breaking change in the mail gem - https://github.com/mikel/mail/commit/7e1196bd29815a0901d7290c82a332c0959b163a
36
- arguments: Gem::Version.new(Mail::VERSION.version) >= Gem::Version.new("2.8.0") ? %w[-i] : "-i"
35
+ arguments: %w[-i]
37
36
 
38
37
  add_delivery_method :test, Mail::TestMailer
39
38
  end
@@ -8,9 +8,9 @@ module ActionMailer
8
8
 
9
9
  module VERSION
10
10
  MAJOR = 7
11
- MINOR = 1
12
- TINY = 5
13
- PRE = "1"
11
+ MINOR = 2
12
+ TINY = 3
13
+ PRE = nil
14
14
 
15
15
  STRING = [MAJOR, MINOR, TINY, PRE].compact.join(".")
16
16
  end
@@ -6,7 +6,7 @@ module ActionMailer
6
6
  # = Action Mailer \InlinePreviewInterceptor
7
7
  #
8
8
  # Implements a mailer preview interceptor that converts image tag src attributes
9
- # that use inline cid: style URLs to data: style URLs so that they are visible
9
+ # that use inline +cid:+ style URLs to +data:+ style URLs so that they are visible
10
10
  # when previewing an HTML email in a web browser.
11
11
  #
12
12
  # This interceptor is enabled by default. To disable it, delete it from the
@@ -114,14 +114,13 @@ module ActionMailer
114
114
  end
115
115
 
116
116
  private
117
- def method_missing(method_name, *args)
118
- if @mailer.action_methods.include?(method_name.to_s)
119
- ActionMailer::Parameterized::MessageDelivery.new(@mailer, method_name, @params, *args)
117
+ def method_missing(method_name, ...)
118
+ if @mailer.action_methods.include?(method_name.name)
119
+ ActionMailer::Parameterized::MessageDelivery.new(@mailer, method_name, @params, ...)
120
120
  else
121
121
  super
122
122
  end
123
123
  end
124
- ruby2_keywords(:method_missing)
125
124
 
126
125
  def respond_to_missing?(method, include_all = false)
127
126
  @mailer.respond_to?(method, include_all)
@@ -129,11 +128,10 @@ module ActionMailer
129
128
  end
130
129
 
131
130
  class MessageDelivery < ActionMailer::MessageDelivery # :nodoc:
132
- def initialize(mailer_class, action, params, *args)
133
- super(mailer_class, action, *args)
131
+ def initialize(mailer_class, action, params, ...)
132
+ super(mailer_class, action, ...)
134
133
  @params = params
135
134
  end
136
- ruby2_keywords(:initialize)
137
135
 
138
136
  private
139
137
  def processed_mailer
@@ -25,31 +25,7 @@ module ActionMailer
25
25
  mattr_accessor :preview_interceptors, instance_writer: false, default: [ActionMailer::InlinePreviewInterceptor]
26
26
  end
27
27
 
28
- def preview_path
29
- ActionMailer.deprecator.warn(<<-MSG.squish)
30
- Using preview_path option is deprecated and will be removed in Rails 7.2.
31
- Please use preview_paths instead.
32
- MSG
33
- self.class.preview_paths.first
34
- end
35
-
36
28
  module ClassMethods
37
- def preview_path=(value)
38
- ActionMailer.deprecator.warn(<<-MSG.squish)
39
- Using preview_path= option is deprecated and will be removed in Rails 7.2.
40
- Please use preview_paths= instead.
41
- MSG
42
- self.preview_paths << value
43
- end
44
-
45
- def preview_path
46
- ActionMailer.deprecator.warn(<<-MSG.squish)
47
- Using preview_path option is deprecated and will be removed in Rails 7.2.
48
- Please use preview_paths instead.
49
- MSG
50
- self.preview_paths.first
51
- end
52
-
53
29
  # Register one or more Interceptors which will be called before mail is previewed.
54
30
  def register_preview_interceptors(*interceptors)
55
31
  interceptors.flatten.compact.each { |interceptor| register_preview_interceptor(interceptor) }
@@ -160,26 +160,6 @@ module ActionMailer
160
160
  mailer = mailer.instance_variable_get(:@mailer)
161
161
  end
162
162
 
163
- if args.is_a?(Hash)
164
- ActionMailer.deprecator.warn <<~MSG
165
- Passing a Hash to the assert_enqueued_email_with :args kwarg causes the
166
- Hash to be treated as params. This behavior is deprecated and will be
167
- removed in Rails 7.2.
168
-
169
- To specify a params Hash, use the :params kwarg:
170
-
171
- assert_enqueued_email_with MyMailer, :my_method, params: { my_param: "value" }
172
-
173
- Or, to specify named mailer args as a Hash, wrap the Hash in an array:
174
-
175
- assert_enqueued_email_with MyMailer, :my_method, args: [{ my_arg: "value" }]
176
- # OR
177
- assert_enqueued_email_with MyMailer, :my_method, args: [my_arg: "value"]
178
- MSG
179
-
180
- params, args = args, nil
181
- end
182
-
183
163
  args = Array(args) unless args.is_a?(Proc)
184
164
  queue ||= mailer.deliver_later_queue_name || ActiveJob::Base.default_queue_name
185
165
 
@@ -1,7 +1,9 @@
1
1
  <% module_namespacing do -%>
2
2
  class <%= class_name %>Mailer < ApplicationMailer
3
- <% actions.each do |action| -%>
3
+ <% actions.each_with_index do |action, index| -%>
4
+ <% if index != 0 -%>
4
5
 
6
+ <% end -%>
5
7
  # Subject can be set in your I18n file at config/locales/en.yml
6
8
  # with the following lookup:
7
9
  #
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: actionmailer
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.1.5.1
4
+ version: 7.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Heinemeier Hansson
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2024-12-10 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: activesupport
@@ -16,118 +15,70 @@ dependencies:
16
15
  requirements:
17
16
  - - '='
18
17
  - !ruby/object:Gem::Version
19
- version: 7.1.5.1
18
+ version: 7.2.3
20
19
  type: :runtime
21
20
  prerelease: false
22
21
  version_requirements: !ruby/object:Gem::Requirement
23
22
  requirements:
24
23
  - - '='
25
24
  - !ruby/object:Gem::Version
26
- version: 7.1.5.1
25
+ version: 7.2.3
27
26
  - !ruby/object:Gem::Dependency
28
27
  name: actionpack
29
28
  requirement: !ruby/object:Gem::Requirement
30
29
  requirements:
31
30
  - - '='
32
31
  - !ruby/object:Gem::Version
33
- version: 7.1.5.1
32
+ version: 7.2.3
34
33
  type: :runtime
35
34
  prerelease: false
36
35
  version_requirements: !ruby/object:Gem::Requirement
37
36
  requirements:
38
37
  - - '='
39
38
  - !ruby/object:Gem::Version
40
- version: 7.1.5.1
39
+ version: 7.2.3
41
40
  - !ruby/object:Gem::Dependency
42
41
  name: actionview
43
42
  requirement: !ruby/object:Gem::Requirement
44
43
  requirements:
45
44
  - - '='
46
45
  - !ruby/object:Gem::Version
47
- version: 7.1.5.1
46
+ version: 7.2.3
48
47
  type: :runtime
49
48
  prerelease: false
50
49
  version_requirements: !ruby/object:Gem::Requirement
51
50
  requirements:
52
51
  - - '='
53
52
  - !ruby/object:Gem::Version
54
- version: 7.1.5.1
53
+ version: 7.2.3
55
54
  - !ruby/object:Gem::Dependency
56
55
  name: activejob
57
56
  requirement: !ruby/object:Gem::Requirement
58
57
  requirements:
59
58
  - - '='
60
59
  - !ruby/object:Gem::Version
61
- version: 7.1.5.1
60
+ version: 7.2.3
62
61
  type: :runtime
63
62
  prerelease: false
64
63
  version_requirements: !ruby/object:Gem::Requirement
65
64
  requirements:
66
65
  - - '='
67
66
  - !ruby/object:Gem::Version
68
- version: 7.1.5.1
67
+ version: 7.2.3
69
68
  - !ruby/object:Gem::Dependency
70
69
  name: mail
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - "~>"
74
- - !ruby/object:Gem::Version
75
- version: '2.5'
76
- - - ">="
77
- - !ruby/object:Gem::Version
78
- version: 2.5.4
79
- type: :runtime
80
- prerelease: false
81
- version_requirements: !ruby/object:Gem::Requirement
82
- requirements:
83
- - - "~>"
84
- - !ruby/object:Gem::Version
85
- version: '2.5'
86
- - - ">="
87
- - !ruby/object:Gem::Version
88
- version: 2.5.4
89
- - !ruby/object:Gem::Dependency
90
- name: net-imap
91
- requirement: !ruby/object:Gem::Requirement
92
- requirements:
93
- - - ">="
94
- - !ruby/object:Gem::Version
95
- version: '0'
96
- type: :runtime
97
- prerelease: false
98
- version_requirements: !ruby/object:Gem::Requirement
99
- requirements:
100
- - - ">="
101
- - !ruby/object:Gem::Version
102
- version: '0'
103
- - !ruby/object:Gem::Dependency
104
- name: net-pop
105
- requirement: !ruby/object:Gem::Requirement
106
- requirements:
107
- - - ">="
108
- - !ruby/object:Gem::Version
109
- version: '0'
110
- type: :runtime
111
- prerelease: false
112
- version_requirements: !ruby/object:Gem::Requirement
113
- requirements:
114
- - - ">="
115
- - !ruby/object:Gem::Version
116
- version: '0'
117
- - !ruby/object:Gem::Dependency
118
- name: net-smtp
119
70
  requirement: !ruby/object:Gem::Requirement
120
71
  requirements:
121
72
  - - ">="
122
73
  - !ruby/object:Gem::Version
123
- version: '0'
74
+ version: 2.8.0
124
75
  type: :runtime
125
76
  prerelease: false
126
77
  version_requirements: !ruby/object:Gem::Requirement
127
78
  requirements:
128
79
  - - ">="
129
80
  - !ruby/object:Gem::Version
130
- version: '0'
81
+ version: 2.8.0
131
82
  - !ruby/object:Gem::Dependency
132
83
  name: rails-dom-testing
133
84
  requirement: !ruby/object:Gem::Requirement
@@ -182,12 +133,11 @@ licenses:
182
133
  - MIT
183
134
  metadata:
184
135
  bug_tracker_uri: https://github.com/rails/rails/issues
185
- changelog_uri: https://github.com/rails/rails/blob/v7.1.5.1/actionmailer/CHANGELOG.md
186
- documentation_uri: https://api.rubyonrails.org/v7.1.5.1/
136
+ changelog_uri: https://github.com/rails/rails/blob/v7.2.3/actionmailer/CHANGELOG.md
137
+ documentation_uri: https://api.rubyonrails.org/v7.2.3/
187
138
  mailing_list_uri: https://discuss.rubyonrails.org/c/rubyonrails-talk
188
- source_code_uri: https://github.com/rails/rails/tree/v7.1.5.1/actionmailer
139
+ source_code_uri: https://github.com/rails/rails/tree/v7.2.3/actionmailer
189
140
  rubygems_mfa_required: 'true'
190
- post_install_message:
191
141
  rdoc_options: []
192
142
  require_paths:
193
143
  - lib
@@ -195,7 +145,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
195
145
  requirements:
196
146
  - - ">="
197
147
  - !ruby/object:Gem::Version
198
- version: 2.7.0
148
+ version: 3.1.0
199
149
  required_rubygems_version: !ruby/object:Gem::Requirement
200
150
  requirements:
201
151
  - - ">="
@@ -203,8 +153,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
203
153
  version: '0'
204
154
  requirements:
205
155
  - none
206
- rubygems_version: 3.5.22
207
- signing_key:
156
+ rubygems_version: 3.6.9
208
157
  specification_version: 4
209
158
  summary: Email composition and delivery framework (part of Rails).
210
159
  test_files: []