Anonymous | Login | Signup for a new account | 2021-04-11 07:20 BST | ![]() |
Main | My View | View Issues | Change Log | Roadmap |
View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
0000704 | SiT! | triggers | public | 2009-05-19 16:52 | 2013-05-04 17:56 | ||||
Reporter | ivan | ||||||||
Assigned To | ivan | ||||||||
Priority | normal | Severity | minor | Reproducibility | always | ||||
Status | resolved | Resolution | fixed | ||||||
Platform | OS | OS Version | |||||||
Product Version | 3.45 | ||||||||
Target Version | 3.90beta1 | Fixed in Version | Current GIT | ||||||
Summary | 0000704: Optional trigger parameters that are not provided can cause errors in trigger rules | ||||||||
Description | If a trigger has parameters that are not required (i.e. Optional) and the trigger call does not provide values for those parameter and a trigger rule uses one of those same parameters an error can result because the {param} variable within the trigger rule will be replaced with an empty string leading to a rule like === TRUE which is obviously invalid. | ||||||||
Tags | No tags attached. | ||||||||
Attached Files | |||||||||
![]() |
||||||||||||||||
|
![]() |
|
kieran (administrator) 2009-07-24 16:40 |
Bumping to 3.60, it's not causing problems atm and should be solved by the new triggers UI. |
ivan (administrator) 2012-11-03 14:50 |
Review to see what the current status is. |
paulh (administrator) 2013-05-04 16:36 |
To reproduce this issue create a notification on incident created and enable a check for priority though don't enter a priority and you get the following error 2013-05-04T16:34:00+01:00 /sit4/incident_new.php Application Warning [512] Error in trigger rule for TRIGGER_INCIDENT_CREATED, check your <a href='triggers.php'>trigger rules</a> ID: 43, rule: {incidentpriorityid}== (in line 317 of file /home/paulh/git/paulheaneys-sit/lib/trigger.class.php) and in the apache logs [Sat May 04 16:34:00 2013] [error] [client ::1] PHP Parse error: syntax error, unexpected ';' in /home/paulh/git/paulheaneys-sit/lib/trigger.class.php(310) : eval()'d code on line 1, referer: http://localhost/sit4/incident_new.php?action=incidentform&type=support&contactid=4&maintid=1&producttext=Example+Product&productid=1&updateid=0&siteid=1&win= [^] [Sat May 04 16:34:00 2013] [error] [client ::1] PHP Stack trace:, referer: http://localhost/sit4/incident_new.php?action=incidentform&type=support&contactid=4&maintid=1&producttext=Example+Product&productid=1&updateid=0&siteid=1&win= [^] [Sat May 04 16:34:00 2013] [error] [client ::1] PHP 1. {main}() /home/paulh/git/paulheaneys-sit/incident_new.php:0, referer: http://localhost/sit4/incident_new.php?action=incidentform&type=support&contactid=4&maintid=1&producttext=Example+Product&productid=1&updateid=0&siteid=1&win= [^] [Sat May 04 16:34:00 2013] [error] [client ::1] PHP 2. TriggerEvent->TriggerEvent() /home/paulh/git/paulheaneys-sit/incident_new.php:893, referer: http://localhost/sit4/incident_new.php?action=incidentform&type=support&contactid=4&maintid=1&producttext=Example+Product&productid=1&updateid=0&siteid=1&win= [^] [Sat May 04 16:34:00 2013] [error] [client ::1] PHP 3. Trigger->fire() /home/paulh/git/paulheaneys-sit/lib/trigger.class.php:53, referer: http://localhost/sit4/incident_new.php?action=incidentform&type=support&contactid=4&maintid=1&producttext=Example+Product&productid=1&updateid=0&siteid=1&win= [^] |
paulh (administrator) 2013-05-04 17:50 |
5232df37 adds check that optional parameters are filled in, don't think there is any point in checking the command before execution as its no different the running the command and getting the error (if we do need to check it won't be trivial) |
![]() |
|||
Date Modified | Username | Field | Change |
2009-05-19 16:52 | ivan | New Issue | |
2009-05-19 16:54 | ivan | Relationship added | parent of 0000350 |
2009-05-19 16:56 | ivan | Relationship added | parent of 0000685 |
2009-05-19 16:56 | ivan | Status | new => confirmed |
2009-05-19 16:56 | ivan | Target Version | => 3.50 |
2009-07-24 16:40 | kieran | Note Added: 0001386 | |
2009-07-24 16:40 | kieran | Assigned To | => kieran |
2009-07-24 16:40 | kieran | Target Version | 3.50 => 3.60 |
2009-08-17 12:30 | kieran | Target Version | 3.60 => 3.80 |
2009-08-17 12:31 | kieran | Status | confirmed => assigned |
2010-02-20 17:03 | paulh | Target Version | 3.60 LTS => 4.0 |
2010-02-20 17:04 | paulh | Relationship added | child of 0001089 |
2011-02-14 13:25 | ivan | Target Version | 4.0 => 3.90beta1 |
2012-11-03 14:50 | ivan | Assigned To | kieran => ivan |
2012-11-03 14:50 | ivan | Note Added: 0004577 | |
2013-05-04 16:36 | paulh | Note Added: 0004815 | |
2013-05-04 17:50 | paulh | Note Added: 0004816 | |
2013-05-04 17:56 | paulh | Status | assigned => resolved |
2013-05-04 17:56 | paulh | Resolution | open => fixed |
2013-05-04 17:56 | paulh | Fixed in Version | => Current GIT |
Copyright © 2000 - 2021 MantisBT Team |