On Fri, Feb 07, 2014 at 11:10:52AM -0500, Len Jaffe wrote:
>  my $tickets = RT::Tickets->new(GetCurrentUser());
>  my $queue ='foo'
>  $tickets->LimitCustomField(CUSTOMFIELD => $internal_gid, OPERATOR => '=',
> VALUE => "i$generic_id", QUEUE => $queue );
>  my $ticket = $tickets->Next;
> The error from ticket->Next() is:
> 
> [Fri Feb  7 16:00:07 2014] [warning]: RT::Queue '{83}' doesn't exist,
> parsed from '{83}.{Internal_GenericID}'
> 
> The queue in question is the queue with ID 83, and does exist. I just added
> the ticket to it.

In the future, please leave on the part of the warning message which
includes that it happened in lib/RT/Tickets.pm with a line number, it
saves time.

> Is this a known bug in queue name handling, is it something I've done
> > wrong, is there a known workaround?

$Tickets->LimitCustomField is used infrequently (unused in core on
Tickets).
Is there a reason you're not using TicketSQL (what's visible in the
Query Builder when you build a query?)

$tickets->FromSQL("CF.{Foo} = 'i$generic_id');
possible with a "And Queue = '$queue'" in there or if you don't want
to limit on Queue, you can use CF.83.{Foo}.

The problem is that passing QUEUE to LimitCustomField is undocumented
and as a result poorly supported by the code that deciphers custom
field names.  However, without digging deeper, I don't know that
CustomFieldDecipher of LimitCustomField needs the bugfix.

-kevin

Attachment: pgpFRwqtRUXX9.pgp
Description: PGP signature

Reply via email to