Issue 2550936
Created on 2017-03-11 01:50 by rouilj, last changed 2023-07-20 02:15 by rouilj.
File name |
Uploaded |
Description |
Edit |
Remove |
message_file_prop_update_via_email.patch
|
rouilj,
2017-03-11 02:36
|
patch to make prop setting for files and messages work if there is a message body or file attachment. |
|
|
msg5942 |
Author: [hidden] (rouilj) |
Date: 2017-03-11 01:50 |
|
When updating an issue via email with the following tag at the end:
[messages=+25;files=+10]
the change only took effect if there was no message created or file
added. Otherwise setting messages/files on the subject line is
ignored.
The key is not to trigger/run this code (from create_msg, but similar
in create_file):
if self.nodeid:
# add the message to the node's list
messages = self.cl.get(self.nodeid, 'messages') # **
messages.append(message_id)
self.props['messages'] = messages
It looks like this code gets the message list from the database and
discards the pending changes. So the modified version of the message
field, created by parsing the subject properties, is discarded.
|
msg5943 |
Author: [hidden] (rouilj) |
Date: 2017-03-11 02:36 |
|
Here is the patch.
In retrospect, I wonder if ignoring the files and messages property
setting was intentional and the rationale was just not recorded in
the file.
I am going to have this sit here for others to comment if fixing
this is a good idea.
-- rouilj
|
|
Date |
User |
Action |
Args |
2023-07-20 02:15:48 | rouilj | set | resolution: remind |
2017-03-18 15:45:34 | rouilj | set | title: email gateway discards changes to messages and files if there is a message body -> email gateway discards changes to messages and files (done with subject tag) if there is a message body |
2017-03-11 02:37:00 | rouilj | set | keywords:
+ patch assignee: rouilj -> messages:
+ msg5943 files:
+ message_file_prop_update_via_email.patch |
2017-03-11 01:50:52 | rouilj | set | status: new -> open |
2017-03-11 01:50:44 | rouilj | create | |
|