Re: FW: setting up e-mail notifications

"Kaplan, Andrew H." <[email protected]>
Newsgroups gmane.comp.bug-tracking.roundup.user
Message-ID <[email protected]>
Hello John --

I made the suggested change to the script, and the output now reads as follows:

Created 				ID 				Activity 				Title 
-> 					-> 				-> 					critical 
5 days ago 				5 				5 days ago 				Install I/O into Z600 workstation with SAS drive 
-> 					-> 				-> 					urgent 
1 week ago 				1 				1/2 an hour ago 			Replacement of McAfee AntiVirus with Microsoft Security Essentials 
1 week ago 				2 				2 days ago 				Conversion of the roarchive database webpages 
4 days ago 				6 				4 days ago 				Nicholas Patient restore... big time 

That makes much more sense, and thanks again for looking into this.

 

-----Original Message-----
From: John Kristensen [mailto:[email protected]] 
Sent: Saturday, August 11, 2012 12:16 AM
To: Kaplan, Andrew H.
Cc: [email protected]
Subject: Re: [Roundup-users] FW: setting up e-mail notifications

Hello Andrew,

On 11/08/12 00:42, Kaplan, Andrew H. wrote:
> Hello --
>
> The latest version of the script listed in option three has been tested successfully on our
> system. Thank-you for your help and patience with me on this issue.
>

Glad we managed to get that sorted out :D

> Question: I posted a message concerning the unusual output that was observed with the
> roundup-reminder.py script. Here is another example:
>
> Created 			ID 			Activity 			Title
> -> 				-> 			-> 				critical
> in 2 days 			5 			2 days ago 			Install I/O into Z600 workstation with SAS drive
> -> 				-> 			-> 				urgent
> in 6 days 			1 			2 minutes ago 		Replacement of McAfee AntiVirus with Microsoft Security Essentials
> tomorrow 			6 			yesterday 			Nicholas Patient restore... big time
> in 6 days 			2 			yesterday 			Conversion of the roarchive database webpages
> -> -				> 			-> 				feature
> tomorrow 			7 			yesterday 			Add the WebEx configuration procedure to the knowledgebase
>
> The text in the Created column appears to point to events that will apepar in the future as opposed to having been created
> in the past. Any ideas as to what would be causing this, and how it can be corrected?
>
> Thanks.
>

If you are getting these future dates when looking at the HTML version 
of the email, then I may have a solution...

I have had a quick skim through the round-reminder script [1] and it 
appears the creation intervals for the HTML part of the email is being 
generated incorrectly on line 146:

   creation = (date.Date('.') - creation_date).pretty()

Subtracting the 'creation_date' from 'Today' will result in a positive 
date interval, which will then translate into a future time when 
pretty() is called. If you replace this line with:

   creation = (creation_date - date.Date('.')).pretty()

you should get something a bit more sensible.

I will submit a patch so this script gets fixed in the next roundup release.

SeeYa,
John.

[1] 
http://roundup.hg.sourceforge.net/hgweb/roundup/roundup/file/beb8d43f4d9d/scripts/roundup-reminder


The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.