Roundup Tracker - Issues

Message5770

Author rouilj
Recipients Ivan Pozdeev, pefu, rouilj
Date 2016-07-06.22:03:24
Message-id <1467842604.82.0.171157049042.issue2550906@psf.upfronthosting.co.za>
In-reply-to
This isn't that different from:

http://www.roundup-tracker.org/docs/customizing.html#stop-nosy-messages-going-to-people-on-vacation

so it could be done by a reactor in theory. I think the code at the
vacation url just copies (what was at the time) the function
roundupdb.py::nosymessage(). Then modifies it to exclude the people on
vacation.

That seems like a lot of code to duplicate and it will be out of date
if there are other updates to nosymessage.

However it has the distinct advantage that it decouples the core code
from the tracker schema. I think this is required.

If we want to support this somehow in the core, Maybe all we need to
do is add:

   nosymessage(..., include_author=None )

and set that value to False if:

   the user chooses no or if the user choses new and there is no
   old_data passed to the reactor.

or set it to True if the default value is chosen and change code
accordingly. None would be the default case.

Alternatively maybe some registration method could be used to register
a "user_email_preferences" action to call a function that will return
none, true or false indicating: default, yes, no respectively?

(We could pass a callable as include_author with a defined argument
list and have the code do the right thing based on argument type.)

Also the whole nosymessage() mechanism really does need to be redesigned to
allow templating (even basic % format templating could help).

   Hello:

   issue %{issue}s has changed ....

   ...

and to make it more flexible.

So I am changing this to medium effort. Even without
templating/redesign it's a bit more than I thought initially.
History
Date User Action Args
2016-07-06 22:03:24rouiljsetmessageid: <1467842604.82.0.171157049042.issue2550906@psf.upfronthosting.co.za>
2016-07-06 22:03:24rouiljsetrecipients: + rouilj, pefu, Ivan Pozdeev
2016-07-06 22:03:24rouiljlinkissue2550906 messages
2016-07-06 22:03:24rouiljcreate