https://www.redmine.org/https://www.redmine.org/favicon.ico?16793021292013-09-04T09:36:11ZRedmineRedmine - Defect #14792: Don't add a display name and extra angle brackets in List-Id header fieldhttps://www.redmine.org/issues/14792?journal_id=515822013-09-04T09:36:11ZToshi MARUYAMA
<ul><li><strong>Related to</strong> <i><a class="issue tracker-3 status-1 priority-4 priority-default" href="/issues/13359">Patch #13359</a>: Better List-Id to help aid Gmail filtering</i> added</li></ul> Redmine - Defect #14792: Don't add a display name and extra angle brackets in List-Id header fieldhttps://www.redmine.org/issues/14792?journal_id=900412019-02-11T12:38:33ZGo MAEDA
<ul><li><strong>Related to</strong> <i><a class="issue tracker-1 status-5 priority-4 priority-default closed" href="/issues/30785">Defect #30785</a>: Mail handler does not ignore emails sent from emission email address if Setting.mail_from includes display name</i> added</li></ul> Redmine - Defect #14792: Don't add a display name and extra angle brackets in List-Id header fieldhttps://www.redmine.org/issues/14792?journal_id=900872019-02-13T03:05:08ZGo MAEDA
<ul><li><strong>File</strong> <a href="/attachments/22399">fix-14792.diff</a> <a class="icon-only icon-download" title="Download" href="/attachments/download/22399/fix-14792.diff">fix-14792.diff</a> added</li><li><strong>Priority</strong> changed from <i>Low</i> to <i>Normal</i></li><li><strong>Target version</strong> set to <i>4.0.2</i></li></ul><p>You can fix this issue with the attached patch.</p> Redmine - Defect #14792: Don't add a display name and extra angle brackets in List-Id header fieldhttps://www.redmine.org/issues/14792?journal_id=901122019-02-14T02:05:55ZGo MAEDA
<ul></ul><p>The patch attached in <a class="issue tracker-2 status-5 priority-4 priority-default closed" title="Feature: Authors name in from address of email notifications (Closed)" href="https://www.redmine.org/issues/5913#note-17">#5913#note-17</a> also fixes this issue. It is unnecessary to merge <a class="attachment" href="https://www.redmine.org/attachments/22399">fix-14792.diff</a> if that patch is merged.</p> Redmine - Defect #14792: Don't add a display name and extra angle brackets in List-Id header fieldhttps://www.redmine.org/issues/14792?journal_id=901632019-02-15T23:54:12ZGo MAEDA
<ul><li><strong>Related to</strong> <i><a class="issue tracker-2 status-5 priority-4 priority-default closed" href="/issues/5913">Feature #5913</a>: Authors name in from address of email notifications</i> added</li></ul> Redmine - Defect #14792: Don't add a display name and extra angle brackets in List-Id header fieldhttps://www.redmine.org/issues/14792?journal_id=901652019-02-16T00:01:00ZGo MAEDA
<ul><li><strong>Assignee</strong> set to <i>Go MAEDA</i></li><li><strong>Target version</strong> changed from <i>4.0.2</i> to <i>4.1.0</i></li><li><strong>Resolution</strong> set to <i>Fixed</i></li></ul><p>Fixed in <a class="changeset" title="Show author's name in the From field of email notifications (#5913). Patch by Go MAEDA." href="https://www.redmine.org/projects/redmine/repository/svn/revisions/17870">r17870</a> along with <a class="issue tracker-2 status-5 priority-4 priority-default closed" title="Feature: Authors name in from address of email notifications (Closed)" href="https://www.redmine.org/issues/5913">#5913</a>.</p>
<p>I will commit the following test later.</p>
<pre><code class="diff syntaxhl"><span class="gh">Index: test/unit/mailer_test.rb
===================================================================
</span><span class="gd">--- test/unit/mailer_test.rb (リビジョン 17870)
</span><span class="gi">+++ test/unit/mailer_test.rb (作業コピー)
</span><span class="p">@@ -213,6 +213,14 @@</span>
assert_equal issue.author.login, mail.header['X-Redmine-Sender'].to_s
end
+ def test_email_headers_list_id_should_not_include_display_name
<span class="gi">+ Setting.mail_from = 'Redmine <redmine@example.net>'
+ issue = Issue.find(1)
+ Mailer.deliver_issue_add(issue)
+ mail = last_email
+ assert_equal '<redmine.example.net>', mail.header['List-Id'].to_s
+ end
+
</span> def test_plain_text_mail
Setting.plain_text_mail = 1
journal = Journal.find(2)
</code></pre> Redmine - Defect #14792: Don't add a display name and extra angle brackets in List-Id header fieldhttps://www.redmine.org/issues/14792?journal_id=901812019-02-16T14:45:54ZGo MAEDA
<ul></ul><p>Adding a test method is too much. We can test that display name and other stuff is not included by adding only one line.</p>
<pre><code class="diff syntaxhl"><span class="gh">Index: test/unit/mailer_test.rb
===================================================================
</span><span class="gd">--- test/unit/mailer_test.rb (リビジョン 17872)
</span><span class="gi">+++ test/unit/mailer_test.rb (作業コピー)
</span><span class="p">@@ -198,11 +198,13 @@</span>
end
def test_email_headers
<span class="gi">+ Setting.mail_from = 'Redmine <redmine@example.net>'
</span> issue = Issue.find(1)
Mailer.deliver_issue_add(issue)
mail = last_email
assert_equal 'All', mail.header['X-Auto-Response-Suppress'].to_s
assert_equal 'auto-generated', mail.header['Auto-Submitted'].to_s
assert_equal '<redmine.example.net>', mail.header['List-Id'].to_s
end
</code></diff></pre> Redmine - Defect #14792: Don't add a display name and extra angle brackets in List-Id header fieldhttps://www.redmine.org/issues/14792?journal_id=901822019-02-16T22:57:49ZGo MAEDA
<ul><li><strong>Subject</strong> changed from <i>Don't add angle brackets in List-Id / mailer.rb</i> to <i>Don't add a display name and extra angle brackets in List-Id header field</i></li><li><strong>Status</strong> changed from <i>New</i> to <i>Closed</i></li></ul><p>Updated the test to catch this issue (<a class="changeset" title="Test that List-Id header field does not include display name and extra angle brackets (#14792). ..." href="https://www.redmine.org/projects/redmine/repository/svn/revisions/17873">r17873</a>).</p>