Some things I tried, I added this to the last line on trac-post-commit-
hook:
import traceback
        traceback.print_exc(file=sys.stderr)
        print 'last line'
On my log page I only get "last line". Where and what can I insert to
print out any needed information in trac-post-commit-hook script?
Just want you know I don't know python much, you ahve to give me
exactly syntex for me to implement it. Sorry about that.
Best regards
Lynda

On Jan 8, 11:48 am, Olemis Lang <[email protected]> wrote:
> On Fri, Jan 8, 2010 at 2:18 PM, lynda <[email protected]> wrote:
> > When I commented out these 2 lines related with email notification in
> > trac-post-commit-hook script:
> > line 107: # from trac.ticket.notification import TicketNotifyEmail
> > line 186: #tn = TicketNotifyEmail(self.env)
> >  The script still does not update my trac ticket and no error out yet.
> > Is commenting out email function a right way to identify if the
> > notification caused the not updating tickets?
>
> AFAICR ... the script performs all processing (ticket updates and so
> on ...) before sending e-mails ... so that should not be the problem
> (CMIIW)
>
> > Can anyone suggest other
> > ways to find the problem?
> > What can i do to debug this issue?
> > I have download SVN:Notify module from cpan,
>
> Is it a Perl module ?
>
> > and so far my SVN"Notify
> > has not been sending email out yet when I test it from window command
> > line using my gmail account.
>
> Notification e-mails are sent by Trac . That's one thing, whereas
> commit hook not working is another thing. If you want to debug
> notifications I suggest you to configure Trac notifications in
> trac.ini and use tickets (create and modify some just to test ;o). If
> that does not work then you have another problem (... that could be
> solved in a separate thread ;o)
>
> OTOH the post-commit hook needs to be added to the repos hook script
> file (first check point) and has to run successfully from the command
> line (second check point ;o) . You could try to redirect stderr to a
> file inside the script . Something like
>
> {{{
> mailer.py commit "$REPOS" "$REV" /path/to/mailer.conf
>
> }}}
>
> becomes
>
> {{{
> mailer.py commit "$REPOS" "$REV" /path/to/mailer.conf           2> 
> C:\error.log
>
> }}}
>
> --
> Regards,
>
> Olemis.
>
> Blog ES:http://simelo-es.blogspot.com/
> Blog EN:http://simelo-en.blogspot.com/
>
> Featured article:
-- 
You received this message because you are subscribed to the Google Groups "Trac 
Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/trac-users?hl=en.


Reply via email to