Changing email subject line should start a new topic

When someone replies to an email and changes the subject, it should start a new topic, rather than post as a reply to the original topic.

For example, let’s say the subject of the original topic was “Agenda for December” and someone replies by email, changing the subject to “Planning for New Years Party”, then it should create a new topic with the new subject.

The current behavior is particularly confusing for users who receive emails about new posts. In this case, a user replies to a message, changing the subject, and the system emails the message out to everyone, with the subject line appearing to be reverted back.


I have a few requests on here related to converting email conventions to forum conventions when receiving email (e.g., stripping “Fwd:”).

@sam, @codinghorror, is it possible to have proposals reviewed before implementation, in order to get feedback before working on implementation? E.g., can this be the default behavior? Does it need to be implemented as a plugin?

Here are links to the others:

Thanks!

2 Likes

This is rather intentional at the moment. You’d need to have a close look at the email headers, but the chain of reply is clearly indicated there.

If someone wants to start a new topic, they should send a new email.

2 Likes

Hi @codinghorror,

Please note that this common use case is already handled via the web interface via the “reply as linked topic” button:

When the user replies by email and changes the subject line, they almost always want to “reply as linked topic”, and never want Discourse to override their changes.

Wouldn’t you agree?

In any case, some people are interested in generally having Discourse treat incoming emails as if they are emails - and do the necessary conversions - rather than as posts to forum. So, what’s the best way to move forward for us? Can it be an admin setting? Make a plugin? Apply a patch in the Docker file?

1 Like

Sounds like plugin territory.

The feature you describe makes sense to me, but the implementation might be tricky because don’t email clients sometimes mangle subjects (prepend re, truncate, etc.)?

3 Likes

For as long as email exists, people will continue to do this sort of thing.

Maybe an easier answer would be a “reply as linked topic” button on the notification email and/or a link to the category’s create-new-topic email address.

2 Likes

Definitely this, as it makes the most sense. Personally, if I just changed the subject line of an automated email I would not expect the feature OP wants. Not to say it isn’t a good suggestion, but doesn’t seem thematic. As Jonathan Shaw said, this does make sense as a plugin.

Personally, if I just changed the subject line of an automated email I would not expect the feature OP wants.

What do you mean by “automated?” When someone changes the email subject (from “Agenda for December Meeting” to “Post-Meeting Social”) they are changing the subject, which is represented in Discourse as changing topics. Right?

What would you expect to happen? Would you expect Discourse to discard your changes and send email notifications with the previous subject / topic?

At the very least, I would hope that Discourse would reject the email, saying that “changing the topic / subject via reply is not allowed.”

Maybe an easier answer would be a “reply as linked topic” button on the notification email

I’m not really looking for a new feature here. My concern is that email handling functionality does not match expectation (e.g., “reply” unexpectedly does “reply all”).

Yes, that’s what I’d expect to happen. Discourse isn’t a mailing list (even its mailing list mode is a poor relation of a real mailing list) and each email is just a separate notification of an event on the forum. The standard text in the notification email reinforces that: “Visit Topic or reply to this email to respond.”

Incidentally, I am pretty sure that Mailman 2 and 3 would both send the emails with the new Subject: header but would archive the emails alongside the original thread.

One of the great things about Discourse is that (it seems to me) nearly anything can be changed via a plugin. I bet that this is the sort of effect that could easily be changed in that way.

Sorry, by automated, I meant the automation of threads relaying as emails.

I’ll be honest, I’m starting to see your side of the argument. But I was thinking more in the traditional email sense where maybe someone would abbreviate a longer chain of emails in the subject line (therefore, changing the subject line) while forwarding it to someone else out of context. I don’t use the email feature so I was a bit ignorant of what it should be doing and what it currently does. I was also thinking people would change the subject line for meme potential where applicable.

Thanks for keeping an open mind.

someone would abbreviate a longer chain of emails in the subject line while forwarding it to someone else out of context.

Nope, simply doing one of these:

Seems like this email interaction should trigger Discourse’s existing “reply as linked topic,” right?

I bet you could create a plugin to do that. It would just need to check whether the Subject: header is sufficiently different, and take the appropriate action. I’ve never written a Discourse plugin so may be underestimating the task here.

Me neither, but a few people have suggested it, so I’ll give it a whirl!

1 Like

Maybe if you have Start a New Topic via Email ✉ set up then you would just need to intercept the user’s email, check the Subject: header, add “Continuing the discussion…” text, maybe remove the In-Reply-To: header (or whatever it is called), and forward it to the relevant category’s email address.

Yes, Start a New Topic via Email is setup. The decision as to whether an email is a reply or a new post seems to be made here:

https://github.com/discourse/discourse/blob/5a0c8f2b346f8abbbac48604decfe44f92ce443b/lib/email/receiver.rb#L192

1 Like