Modify

Opened 11 years ago

Closed 10 years ago

#11229 closed defect (fixed)

Can't get it to run

Reported by: Zeph Owned by: Zeph
Priority: normal Component: WorkflowNotificationPlugin
Severity: normal Keywords:
Cc: Trac Release: 1.0

Description

Hi, Thanks for your wonderful plugin. But I have a bit of problem getting it to run.

I have set up the default trac notification and that is working fine. So the smtp settings should be correct. But I have problem getting this plugin to work. Am I missing out on some settings?

Thanks for the help

This is what I have in my trac.ini

[components] workflow_notification.* = enabled

[ticket] workflow = ConfigurableTicketWorkflow, TicketWorkflowNotifier

[ticket-workflow-notifications] new_ticket = @created new_ticket.body = ${ticket.description} new_ticket.recipients = ${ticket.reporter}, ${ticket.cc} new_ticket.subject = [tdhelp] #${ticket.id}: ${ticket.summary} when_resolved = resolve when_resolved.body = Ticket ${ticket.id} has been closed! \nStatus is ${ticket.resolution} \n\nView it here: ${link} when_resolved.subject = Ticket ${ticket.id} is closed! when_resolved.recipients = ${ticket.reporter}, ${ticket.cc}

Attachments (0)

Change History (5)

comment:1 Changed 11 years ago by ethan.jucovy@…

Owner: changed from ejucovy to Zeph

Have you customized your [ticket-workflow] settings at all, or are they the defaults?

The plugin does some logging which would help for debugging this. If you don't already have Trac logging configured at the DEBUG level, add (or adjust) this section in your trac.ini file:

[logging]
log_file = trac.log
log_level = DEBUG
log_type = file

Then try creating some tickets and look for messages in the log file from this plugin. I just noticed that the plugin's log messages are badly labelled -- they'll show up with a prefix of "Trac[__init__]" (which should instead be Trac[workflow_notification] -- which I'll fix in the next release) -- so you'll want to look for any lines in the log file that contain the text Trac[__init__], like "2013-07-17 21:16:07,220 Trac[__init__] DEBUG: Notification needs_approval for ticket 508 (action: pendingapproval)"

Could you paste those logging lines here?

comment:2 Changed 11 years ago by Zeph

No. I have not modfied the [ticket-workflow]

[ticket-workflow]
accept = new,assigned,accepted,reopened -> accepted
accept.operations = set_owner_to_self
accept.permissions = TICKET_MODIFY
leave = * -> *
leave.default = 1
leave.operations = leave_status
reassign = new,assigned,accepted,reopened -> assigned
reassign.operations = set_owner
reassign.permissions = TICKET_MODIFY
reopen = closed -> reopened
reopen.operations = del_resolution
reopen.permissions = TICKET_CREATE
resolve = new,assigned,accepted,reopened -> closed
resolve.operations = set_resolution
resolve.permissions = TICKET_MODIFY

After looking at the log, it seems like the plugin was not even ran... There is no log about the plugin... But I noticed a warning about repository '(default)' not found. Sorry I am new to Trac so maybe there is something wrong with my setup. But thanks for your help!

2013-07-19 10:43:20,698 Trac[main] DEBUG: Dispatching <RequestWithSession "POST '/newticket'">
2013-07-19 10:43:20,698 Trac[api] WARNING: Unable to find repository '(default)' for synchronization
2013-07-19 10:43:20,698 Trac[session] DEBUG: Retrieving session for ID u'zeph'
2013-07-19 10:43:20,776 Trac[main] DEBUG: Dispatching <RequestWithSession "GET '/ticket/19'">
2013-07-19 10:43:20,776 Trac[api] WARNING: Unable to find repository '(default)' for synchronization
2013-07-19 10:43:20,776 Trac[session] DEBUG: Retrieving session for ID u'zeph'
2013-07-19 10:43:20,792 Trac[default_workflow] DEBUG: render_ticket_action_control: action "leave"
2013-07-19 10:43:20,792 Trac[default_workflow] DEBUG: render_ticket_action_control: action "resolve"
2013-07-19 10:43:20,792 Trac[default_workflow] DEBUG: render_ticket_action_control: action "reassign"
2013-07-19 10:43:20,792 Trac[default_workflow] DEBUG: render_ticket_action_control: action "accept"
2013-07-19 10:43:20,808 Trac[chrome] DEBUG: Prepare chrome data for request
2013-07-19 10:43:20,980 Trac[main] DEBUG: Dispatching <RequestWithSession "GET '/chrome/site/your_project_logo.png'">
2013-07-19 10:43:20,994 Trac[chrome] WARNING: File your_project_logo.png not found in any of ['k:\\tracproject\\htdocs']
2013-07-19 10:43:20,994 Trac[session] DEBUG: Retrieving session for ID u'zeph'
2013-07-19 10:43:20,994 Trac[main] WARNING: [172.22.34.210] HTTPNotFound: 404 Not Found (File your_project_logo.png not found)
2013-07-19 10:43:20,994 Trac[chrome] DEBUG: Prepare chrome data for request

comment:3 Changed 11 years ago by Zeph

Hi, please ignore the earlier post. I found that the plugin wasn't enabled. So now that it is enabled, I got this. Seems like there is no error but I did not get any email.

2013-07-19 15:48:14,573 Trac[__init__] DEBUG: Notification when_resolved for ticket 15 (action: resolve)
2013-07-19 15:48:14,573 Trac[__init__] DEBUG: Sending notification when_resolved for ticket 15 because there was no condition

comment:4 Changed 11 years ago by Zeph

Ok... Seems like stupid me did not enable smtp

[notification]
smtp_enabled = true

So now it's working now! Thanks!

comment:5 Changed 10 years ago by ejucovy

Resolution: fixed
Status: newclosed

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Zeph.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.