6.0.0-git
2019-03-24

[#10654] Can't autosubmit to a ticket from Horde
Summary Can't autosubmit to a ticket from Horde
Queue Whups
Queue Version 2.0-RC1
Type Bug
State Resolved
Priority 1. Low
Owners jan (at) horde (dot) org
Requester simon (at) simonandkate (dot) net
Created 2011-10-14 (2718 days ago)
Due
Updated 2012-08-30 (2397 days ago)
Assigned 2011-10-14 (2718 days ago)
Resolved 2012-08-09 (2418 days ago)
Milestone
Patch No

History
2012-08-30 08:14:03 Jan Schneider Comment #36 Reply to this comment
Is there a timeframe for these changes to make release in the main 
pear channel?
No
2012-08-30 06:29:02 simon (at) simonandkate (dot) net Comment #35 Reply to this comment
Thanks for all the work on this Jan, I have not yet been able to try 
it to confirm the fix, but will do so this weekend.

Is there a timeframe for these changes to make release in the main 
pear channel?
2012-08-29 12:47:15 Git Commit Comment #34 Reply to this comment
Changes have been made in Git (master):

commit 51eb12a7ddd3462d198e52ee1970870c527856ef
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 19:31:24 2012 +0200

     [jan] Fix auto-submitting of tickets if using groups (Bug #10654).

     Conflicts:

             whups/package.xml

  whups/docs/CHANGES |    1 +
  whups/package.xml  |    1 +
  2 files changed, 2 insertions(+), 0 deletions(-)

http://git.horde.org/horde-git/-/commit/51eb12a7ddd3462d198e52ee1970870c527856ef
2012-08-29 12:47:11 Git Commit Comment #33 Reply to this comment
Changes have been made in Git (master):

commit 83265ac2be9696d444667ce53f5e80cec1edb4fe
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 19:23:36 2012 +0200

     Default to access for all groups (Bug #10654).

  whups/lib/Form/Ticket/CreateStepThree.php |   11 ++++-------
  1 files changed, 4 insertions(+), 7 deletions(-)

http://git.horde.org/horde-git/-/commit/83265ac2be9696d444667ce53f5e80cec1edb4fe
2012-08-29 12:47:06 Git Commit Comment #32 Reply to this comment
Changes have been made in Git (master):

commit e344ad4a6ad40327269adb9e43e8a21986139354
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 15:03:52 2012 +0200

     [jan] Fix adding attachments to problem tickets (Bug #10654).

     Conflicts:

             horde/package.xml

  horde/docs/CHANGES |    1 +
  horde/package.xml  |    1 +
  2 files changed, 2 insertions(+), 0 deletions(-)

http://git.horde.org/horde-git/-/commit/e344ad4a6ad40327269adb9e43e8a21986139354
2012-08-29 12:47:00 Git Commit Comment #31 Reply to this comment
Changes have been made in Git (master):

commit b4cd881e2d14331057e0a96a382b9fb8aa7a1e1c
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 14:28:53 2012 +0200

     Fix adding attachments to problem tickets (Bug #10654).

  horde/services/problem.php |    4 ++--
  1 files changed, 2 insertions(+), 2 deletions(-)

http://git.horde.org/horde-git/-/commit/b4cd881e2d14331057e0a96a382b9fb8aa7a1e1c
2012-08-09 17:34:11 Jan Schneider Assigned to Jan Schneider
State ⇒ Resolved
 
2012-08-09 17:33:55 Git Commit Comment #30 Reply to this comment
Changes have been made in Git (develop):

commit 51eb12a7ddd3462d198e52ee1970870c527856ef
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 19:31:24 2012 +0200

     [jan] Fix auto-submitting of tickets if using groups (Bug #10654).

     Conflicts:

             whups/package.xml

  whups/docs/CHANGES |    1 +
  whups/package.xml  |    1 +
  2 files changed, 2 insertions(+), 0 deletions(-)

http://git.horde.org/horde-git/-/commit/51eb12a7ddd3462d198e52ee1970870c527856ef
2012-08-09 17:33:47 Git Commit Comment #29 Reply to this comment
Changes have been made in Git (FRAMEWORK_4):

commit 45c2e297e8554913cbc290e62986dde270363325
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 19:31:24 2012 +0200

     [jan] Fix auto-submitting of tickets if using groups (Bug #10654).

  whups/docs/CHANGES |    1 +
  whups/package.xml  |    2 ++
  2 files changed, 3 insertions(+), 0 deletions(-)

http://git.horde.org/horde-git/-/commit/45c2e297e8554913cbc290e62986dde270363325
2012-08-09 17:33:44 Git Commit Comment #28 Reply to this comment
Changes have been made in Git (FRAMEWORK_4):

commit 0019012dcc49ec8d0a0fa37285fabfa39dca171f
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 19:23:36 2012 +0200

     Default to access for all groups (Bug #10654).

  whups/lib/Form/Ticket/CreateStepThree.php |   11 ++++-------
  1 files changed, 4 insertions(+), 7 deletions(-)

http://git.horde.org/horde-git/-/commit/0019012dcc49ec8d0a0fa37285fabfa39dca171f
2012-08-09 17:28:49 Git Commit Comment #27 Reply to this comment
Changes have been made in Git (develop):

commit 83265ac2be9696d444667ce53f5e80cec1edb4fe
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 19:23:36 2012 +0200

     Default to access for all groups (Bug #10654).

  whups/lib/Form/Ticket/CreateStepThree.php |   11 ++++-------
  1 files changed, 4 insertions(+), 7 deletions(-)

http://git.horde.org/horde-git/-/commit/83265ac2be9696d444667ce53f5e80cec1edb4fe
2012-08-09 17:28:43 Git Commit Comment #26 Reply to this comment
Changes have been made in Git (develop):

commit e344ad4a6ad40327269adb9e43e8a21986139354
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 15:03:52 2012 +0200

     [jan] Fix adding attachments to problem tickets (Bug #10654).

     Conflicts:

             horde/package.xml

  horde/docs/CHANGES |    1 +
  horde/package.xml  |    1 +
  2 files changed, 2 insertions(+), 0 deletions(-)

http://git.horde.org/horde-git/-/commit/e344ad4a6ad40327269adb9e43e8a21986139354
2012-08-09 13:04:15 Git Commit Comment #25 Reply to this comment
Changes have been made in Git (FRAMEWORK_4):

commit 2d21217e9af93969448f58fd145249cf8452ac42
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 15:03:52 2012 +0200

     [jan] Fix adding attachments to problem tickets (Bug #10654).

  horde/docs/CHANGES |    1 +
  horde/package.xml  |    2 ++
  2 files changed, 3 insertions(+), 0 deletions(-)

http://git.horde.org/horde-git/-/commit/2d21217e9af93969448f58fd145249cf8452ac42
2012-08-09 13:04:11 Git Commit Comment #24 Reply to this comment
Changes have been made in Git (FRAMEWORK_4):

commit fe0d93af0caa609ba2dceccea24983b21560eec5
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 14:28:53 2012 +0200

     Fix adding attachments to problem tickets (Bug #10654).

     Conflicts:

             horde/services/problem.php

  horde/services/problem.php |    4 ++--
  1 files changed, 2 insertions(+), 2 deletions(-)

http://git.horde.org/horde-git/-/commit/fe0d93af0caa609ba2dceccea24983b21560eec5
2012-08-09 13:01:23 Git Commit Comment #23 Reply to this comment
Changes have been made in Git (develop):

commit b4cd881e2d14331057e0a96a382b9fb8aa7a1e1c
Author: Jan Schneider <jan@horde.org>
Date:   Thu Aug 9 14:28:53 2012 +0200

     Fix adding attachments to problem tickets (Bug #10654).

  horde/services/problem.php |    4 ++--
  1 files changed, 2 insertions(+), 2 deletions(-)

http://git.horde.org/horde-git/-/commit/b4cd881e2d14331057e0a96a382b9fb8aa7a1e1c
2012-07-23 13:08:22 bmwnfun (at) gmail (dot) com Comment #22 Reply to this comment
I have been having the same issue today on a new stock install of 
horde and whups (even went so far as to install a testbed server with 
nothing other than whups installed on horde framework).

I was able to get it working without modifying any files at all by 
adding group in the array define. Something like this (notice i define 
group):

array('queue' => 1, 'state' => 1, 'priority' => 1, 'type' => 1,'group' => 1)

Maybe not the best solution, but seemed to be the least intrusive way 
to find a workaround.
2012-06-13 04:54:10 simon (at) simonandkate (dot) net Comment #21 Reply to this comment
Are these tickets in "No Feedback" state watched at all?

I have disabled adding of attachments to auto-submitted tickets, and 
so the submission of tickets now appears to work fine (although it 
does not advise "Your ticket number is...").

The fatal error for web page redirect is not occurring any more.

So - summary:

1. It is running with the section of 
lib/Form/TicketCreateStepThree.php commented out as noted in Comment 
19 below
2. It is successfully creating auto-submitted tickets, but does not 
notify the user of the ticket number
3. Adding attachments to autosubmitted tickets breaks it
4. I am sure that my commenting the groups section out will have 
broken something else, I just haven't found what yet.

Any help available?
2012-06-01 11:50:45 simon (at) simonandkate (dot) net Comment #20 Reply to this comment
One step further, one step back.

If I try and log a Problem from services/Problem.php with an 
attachment, I get an error on the screen:

ErrorInvalid Ticket Id

And the following Debug in log:

2012-06-01T21:45:00+10:00 NOTICE: HORDE [horde] PHP ERROR: Undefined 
variable: result [pid 1698 on line 86 of 
"/var/www/horde4/services/problem.php"]
2012-06-01T21:45:00+10:00 DEBUG: HORDE 1. Horde::errorHandler() 
/var/www/horde4/services/problem.php:86

2012-06-01T21:45:00+10:00 DEBUG: HORDE [horde] 1. 
Horde::errorHandler() /var/www/horde4/services/problem.php:86
  [pid 1698 on line 240 of "/usr/share/pear/Horde.php"]
2012-06-01T21:45:00+10:00 DEBUG: HORDE [horde] Invalid Ticket Id [pid 
1698 on line 27 of 
"/usr/share/pear/Horde/Core/Notification/Handler/Decorator/Hordelog.php"]
2012-06-01T21:45:00+10:00 DEBUG: HORDE [horde] Max memory usage: 
35913728 bytes [pid 1698 on line 476 of 
"/usr/share/pear/Horde/Registry.php"]

The attachment is a 25KB text file.

Logging a ticket with an attachment from within Whups itself works fine.
2012-06-01 11:42:11 simon (at) simonandkate (dot) net Comment #19 Reply to this comment
OK, for some reason the Fatal error is not occurring any more, so I am 
now running lib/Form/TicketCreateStepThree.php with this section 
removed:

          /* Comment permissions. */
          $groups = $GLOBALS['injector']->getInstance('Horde_Group');
          $mygroups = $groups->listGroups($GLOBALS['registry']->getAuth());
          if ($mygroups) {
              foreach (array_keys($mygroups) as $gid) {
                  $grouplist[$gid] = $groups->getName($gid, true);
              }
              asort($grouplist);
              $grouplist = array(0 => _("This comment is visible to
everyone")) + $grouplist;
              $this->addVariable(
                  _("Make this comment visible only to members of a
group?"), 'group',
                  'enum', false, false, null, array($grouplist));
          }


And it seems to be working OK, but I am sure that will have broken 
something else somewhere else!
2012-06-01 11:08:57 simon (at) simonandkate (dot) net Comment #18 Reply to this comment
And this is the function in problem.php that results in the fatal 
error for the redirect:

function _returnToPage()
{
     $url = new Horde_Url(Horde_Util::getFormData('return_url', 
Horde::url('login.php', true, array('app' => 'horde'))));
     $url->redirect();
}


That seems to call this public function in Url.php:

     public function redirect()
     {
         $url = strval($this->setRaw(true));
         if (!strlen($url)) {
             throw new Horde_Url_Exception('Redirect failed: URL is empty.');
         }

         header('Location: ' . $url);
         exit;
     }
2012-06-01 10:55:57 simon (at) simonandkate (dot) net Comment #17 Reply to this comment
OK, I have been doing some more troubleshooting on this.

First of all, reset all the Type / State / Priority etc, and confirmed 
that Horde config is set correctly.

Then tracked down the issue in Api.php to the section that reads:

         if (!$form3->validate($vars, true)) {
             $f3 = var_export($form3->getErrors(), true);
             throw new Whups_Exception("Invalid arguments ($f3)");
         }

Take that out and the ticket is created fine (albeit with an empty 
redirect URL fatal error - the ticket is fine).

Follow that further to lib/Form/TicketCreateStepThree.php. Take out 
the section:

         /* Comment permissions. */
         $groups = $GLOBALS['injector']->getInstance('Horde_Group');
         $mygroups = $groups->listGroups($GLOBALS['registry']->getAuth());
         if ($mygroups) {
             foreach (array_keys($mygroups) as $gid) {
                 $grouplist[$gid] = $groups->getName($gid, true);
             }
             asort($grouplist);
             $grouplist = array(0 => _("This comment is visible to 
everyone")) + $grouplist;
             $this->addVariable(
                 _("Make this comment visible only to members of a 
group?"), 'group',
                 'enum', false, false, null, array($grouplist));
         }

And the ticket is created correctly (same redirect error).

The Fatal error is:

A fatal error has occurred
Redirect failed: URL is empty.

1. _returnToPage() /var/www/horde4/services/problem.php:96
2. Horde_Url->redirect() /var/www/horde4/services/problem.php:15

Details
The full error message is logged in Horde's log file, and is shown 
below only to administrators. Non-administrative users will not see 
error details.

Horde_Url_Exception Object
(
     [_previous:private] =>
     [details] =>
     [message:protected] => Redirect failed: URL is empty.
     [string:private] =>
     [code:protected] => 0
     [file:protected] => /usr/share/pear/Horde/Url.php
     [line:protected] => 326
     [trace:private] => Array
         (
             [0] => Array
                 (
                     [file] => /var/www/horde4/services/problem.php
                     [line] => 15
                     [function] => redirect
                     [class] => Horde_Url
                     [type] => ->
                     [args] => Array
                         (
                         )

                 )

             [1] => Array
                 (
                     [file] => /var/www/horde4/services/problem.php
                     [line] => 96
                     [function] => _returnToPage
                     [args] => Array
                         (
                         )

                 )

         )

)


But hey! at least the ticket is created.
2012-03-21 22:38:09 simon (at) simonandkate (dot) net Comment #16 Reply to this comment
Whether or not it is only a debug error, the UI presents the error 
that matches it, and the action fails - no ticket is logged.

I have listed my config, and worked through some of the structure 
issues. I am not sure what else I can tell you Jan - what other 
troubleshooting can I do to assist?
Still an issue with latest version. Still open to suggestions on how I 
can further troubleshoot this...
2012-01-31 23:14:32 simon (at) simonandkate (dot) net Comment #15 Reply to this comment
Whether or not it is only a debug error, the UI presents the error 
that matches it, and the action fails - no ticket is logged.

I have listed my config, and worked through some of the structure 
issues. I am not sure what else I can tell you Jan - what other 
troubleshooting can I do to assist?
2012-01-31 15:33:27 Jan Schneider State ⇒ No Feedback
 
2011-12-28 15:11:28 Jan Schneider Comment #14 Reply to this comment
But in your logs it's just a DEBUG error and the code seems to happily 
continue running.
2011-11-17 11:26:53 simon (at) simonandkate (dot) net Comment #13 Reply to this comment
Still does it. The error is noted in line 1312 & 1313 of the attachment:

UI error: Invalid arguments (array ( 'group' => 'Invalid data submitted.', ))

Log error:

2011-11-04T13:20:28+10:00 DEBUG: HORDE [horde] Invalid arguments (array (
   'group' => 'Invalid data submitted.',
)) [pid 2544 on line 27 of 
"/usr/share/pear/Horde/Core/Notification/Handler/Decorator/Hordelog.php"]
2011-11-13 20:32:24 Jan Schneider Comment #12 Reply to this comment
There still is no error message in the log. Are you sure this error 
still exists at all?
2011-11-04 03:34:26 simon (at) simonandkate (dot) net Comment #11
New Attachment: hordedebug.txt Download
Reply to this comment
Debug log attached (turned on, generate error, turn off!)

Line 1280+ appears to be the piece of interest.
2011-10-31 17:52:55 Jan Schneider Comment #10 Reply to this comment
You don't have the missing table error though.
2011-10-29 07:25:31 michael (at) bigmichi1 (dot) de Comment #9 Reply to this comment
hi, i'm having the same problem with "Invalid arguments (array ( 
'group' => 'Ung├╝ltige Daten eingegeben.', ))"

i enabled debug in horde config and these are the last few lines befor 
the error pops up:


2011-10-29T09:15:53+02:00 DEBUG: HORDE [wicked] Load config file 
(conf.php; app: wicked) [pid 14065 on line 865 of 
"/var/www/pear/php/Horde.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0003s)
         SELECT queue_id, queue_name FROM whups_queues ORDER BY 
queue_name [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0002s)
         SELECT queue_id, queue_name, queue_description, queue_versioned,
           queue_slug, queue_email FROM whups_queues WHERE queue_id = 
2 [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0002s)
         SELECT queue_id, queue_name, queue_description, queue_versioned,
           queue_slug, queue_email FROM whups_queues WHERE queue_id = 
1 [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0004s)
         SELECT t.type_id, t.type_name FROM whups_types t, whups_types_queues
           tm WHERE tm.queue_id = 1 AND tm.type_id = t.type_id ORDER BY
           t.type_name [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0002s)
         SELECT type_id FROM whups_types_queues WHERE type_default = 1 AND
           queue_id = 1 [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0004s)
         SELECT state_id, state_name FROM whups_states WHERE type_id = 2 AND
           (state_category = 'unconfirmed') ORDER BY state_category, 
state_name [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0002s)
         SELECT attribute_id, attribute_name, attribute_description,
           attribute_type, attribute_params, attribute_required FROM
           whups_attributes_desc WHERE type_id = 2 ORDER BY 
attribute_name [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0003s)
         SELECT state_id, state_name FROM whups_states WHERE type_id = 2 AND
           (state_category = 'new' OR state_category = 'assigned') ORDER BY
           state_category, state_name [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0003s)
         SELECT state_id FROM whups_states WHERE state_default = 1 AND type_id
           = 2 [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0003s)
         SELECT priority_id, priority_name FROM whups_priorities WHERE type_id
           = 2 ORDER BY priority_name [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0002s)
         SELECT priority_id FROM whups_priorities WHERE priority_default = 1
           AND type_id = 2 [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0004s)
         SELECT g.group_uid AS group_uid, g.group_name AS group_name FROM
           horde_groups g, horde_groups_members m WHERE m.user_uid =
           'test@bigmichi1.de' AND g.group_uid = m.group_uid ORDER BY
           g.group_name [pid 14065 on line 803 of 
"/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [whups] SQL  (0,0002s)
         SELECT group_name FROM horde_groups WHERE group_uid = 2 [pid 
14065 on line 803 of "/var/www/pear/php/Horde/Db/Adapter/Base.php"]
2011-10-29T09:15:53+02:00 DEBUG: HORDE [horde] Invalid arguments (array (
   'group' => 'Ung├╝ltige Daten eingegeben.',
)) [pid 14065 on line 27 of 
"/var/www/pear/php/Horde/Core/Notification/Handler/Decorator/Hordelog.php"]



mysql> SELECT g.group_uid AS group_uid, g.group_name AS group_name
     -> FROM horde_groups g, horde_groups_members m
     -> WHERE m.user_uid =  'test@bigmichi1.de'
     -> AND g.group_uid = m.group_uid
     -> ORDER BY g.group_name;
+-----------+------------+
| group_uid | group_name |
+-----------+------------+
|         2 | Admin      |
+-----------+------------+
1 row in set (0.00 sec)


mysql>  SELECT group_name FROM horde_groups WHERE group_uid = 2;
+------------+
| group_name |
+------------+
| Admin      |
+------------+
1 row in set (0.00 sec)

2011-10-27 22:16:57 simon (at) simonandkate (dot) net Comment #8 Reply to this comment
No, I use the default SQL-NG for shares. I'll enable debug logging and 
post back over the weekend.
2011-10-27 21:05:33 Jan Schneider Comment #7 Reply to this comment
Please enable debug logging and paste the backtrace that is logged 
with this error. Also, do you happen to use the SQL (NOT the SQL-NG) 
driver for shares?
2011-10-19 12:45:16 simon (at) simonandkate (dot) net Comment #6 Reply to this comment
I can manually create tickets, so I know it is working.

Auto submit fails as noted. I have no groups in any of the 
whups_*groups SQL tables.

I have Horde groups, yes - is that what this is looking for? If so, 
again it should be fine - there is a HordeTicketAccess LDAP group that 
includes me with permissions to show / read / edit / delete tickets 
(at the group level). It allows me to manually create tickets. It is 
the only permission set against Tickets (whups), and there are no 
child permissions.

Should have checked the logs earlier though:

2011-10-19T22:32:42+10:00 ERR: HORDE [horde] SQL QUERY FAILED: 
SQLSTATE[42S02]: Base table or view not found: 1146 Table 
'horde.whups_groups' doesn't exist
        select * from whups_groups [pid 21254 on line 812 of 
"/usr/share/pear/Horde/Db/Adapter/Base.php"]

It's correct, there is no whups_groups table.

If submitting a ticket needs it, why does it work manually? And why 
don't I have the table?

Whups is at version 2.0-RC2 and has been installed the normal pear 
way, with no modifying, and upgraded from alpha to RC1 then RC2.
2011-10-19 08:22:03 Jan Schneider Comment #5
Summary ⇒ Can't autosubmit to a ticket from Horde
Reply to this comment
I'm not actually calling group anywhere! Nor do I have any groups in SQL.
Are you sure? Because the place where the 'group' field is being added 
explicitly checks if the currently logged-in user has some groups 
(whups/lib/Form/Ticket/CreateStepThree.php line 91).
2011-10-19 07:06:20 simon (at) simonandkate (dot) net Comment #4 Reply to this comment
array('queue' => 1, 'state' => 1, 'priority' => 1, 'type' => 1)

OK, I see that the values in that statement have to match the related 
values in the database. So for Type of 1 (which I have as Fault), the 
matching available states are 6,7,8,9,10, where 6 is unconfirmed. So 
with State 6, Type 1, valid Priorities are 4,5,6. 4 being Low, I now 
have:

array('queue' => 1, 'state' => 6, 'priority' => 4, 'type' => 1)

That should be a valid combination.

Still gives me:
Invalid arguments (array ( 'group' => 'Invalid data submitted.', ))

2011-10-19 06:53:47 simon (at) simonandkate (dot) net Comment #3 Reply to this comment
Upgraded to Whups RC2. Now it does this:

Invalid arguments (array ( 'state' => 'Invalid data submitted.', 
'priority' => 'Invalid data submitted.', 'group' => 'Invalid data 
submitted.', ))

So it's degenerating, not getting better... :(

The Horde code is:

$conf[problems][ticket_params]
array('queue' => 1, 'state' => 1, 'priority' => 1, 'type' => 1)

Looking at select * from whups_states shows:

state_id type_id state_name state_description state_category state_default
1 2 Unconfirmed A ticket has been reported but not yet analyzed unconfirmed 0
2 2 Accepted The ticket has been analyzed and accepted as valid. new 0
3 2 Assigned Someone has accepted responsibility for the ticket. assigned 0
4 2 Resolved The ticket has been resolved. resolved 0
5 2 Canceled The ticket is no longer valid for one reason or another. 
resolved 0
6 1 Unconfirmed A ticket has been reported but not yet analyzed unconfirmed 0
7 1 Accepted The ticket has been analyzed and accepted as valid. new 0
8 1 Assigned Someone has accepted responsibility for the ticket. assigned 0
9 1 Resolved The ticket has been resolved. resolved 0
10 1 Canceled The ticket is no longer valid for one reason or another. 
resolved 0
11 4 Unconfirmed A ticket has been reported but not yet analyzed unconfirmed 0
12 4 Accepted The ticket has been analyzed and accepted as valid. new 0
13 4 Assigned Someone has accepted responsibility for the ticket. assigned 0
14 4 Resolved The ticket has been resolved. resolved 0
15 4 Canceled The ticket is no longer valid for one reason or another. 
resolved 0

With both priority_id and state_id 1 having a type_id of 2, I changed 
the Horde code to be:

array('queue' => 1, 'state' => 1, 'priority' => 1, 'type' => 2)

That gets a bit further:

Invalid arguments (array ( 'group' => 'Invalid data submitted.', ))

I'm not actually calling group anywhere! Nor do I have any groups in SQL.
2011-10-14 09:26:48 Jan Schneider Comment #2
State ⇒ Feedback
Reply to this comment
Cannot reproduce. Make sure that the IDs are correct.
There is some error further down in the method though, fixed by:
http://git.horde.org/horde-git/-/commit/4ea879e116216b5e78f05d4240ad11e4b9212141
2011-10-14 02:09:46 simon (at) simonandkate (dot) net Comment #1
Type ⇒ Bug
State ⇒ Unconfirmed
Priority ⇒ 1. Low
Summary ⇒ Can't autosubmmit to a ticket from Horde
Queue ⇒ Whups
Milestone ⇒
Patch ⇒ No
Reply to this comment
Zitat von Simon Wilson <simon@simonandkate.net>:
$conf[problems][ticket_params] in Horde is set to:  array('queue' => 
1, 'state' => 1, 'priority' => 1, 'type' => 1)

In the Whups database tables, there exist queue of 1, state of 1, 
priority of 1, and type of 1. Yet creating a 'problem' within Horde 
and submitting it generates the following STOP error:

Invalid arguments (array ( 'state' => 'Invalid data submitted.', 
'priority' => 'Invalid data submitted.', ))

Have I got the conf entry wrong?
No, looks correct. Create a ticket on bugs.horde.org.

Jan.

Saved Queries