[rt-users] Skipping Scrip #X because it didn't Prepare

Cena, Stephen (ext. 300) SJC at qvii.com
Mon Aug 15 11:00:30 EDT 2016


Jim - I tried your suggestion and it caused the Scrip to fire every single time. What I ended up doing that worked was I duplicated the test in Custom Condition to Custom Action preparation. So both fields now have:

if ($self->TicketObj->Status eq 'rejected') { return 1; }
if ($self->TicketObj->Status eq 'resolved') { return 1; }
return 0;

What is really weird is on my test system it works flawlessly with only the Custom Condition and Custom action commit code. Basically we just want tickets to re-open if they are in Resolve or Rejected and get Replied to. I'm scratching my head at why the two systems are functioning differently. Is it possible that an earlier Scrip I have could be interfering? Before I had a test environment I'd make changes to our live system for functionality. 

Message: 2
Date: Fri, 12 Aug 2016 14:10:44 -0400
From: Jim Brandt <jbrandt at bestpractical.com>
To: rt-users at lists.bestpractical.com
Subject: Re: [rt-users] Skipping Scrip #X because it didn't Prepare
Message-ID: <147b8081-d7dc-0c02-d01f-6c8b42ee1c96 at bestpractical.com>
Content-Type: text/plain; charset=windows-1252; format=flowed

Do you have anything in the "Custom action preparation code:" box? If not, try adding:

return 1;

so the Prepare step returns successfully.

On 8/12/16 1:50 PM, Cena, Stephen (ext. 300) wrote:
> I have two RT systems: one testing and one production. I have a 
> modified notification Scrip on my test box:
> ----------------------------------------
> Description: On Correspond Reopen Rejected/Resolved Tickets
> Condition: On Correspond
> Action: User Defined
> Template: Blank
> Custom cond:
> If ($self->TicketObj->Status eq ?rejected?) { return 1; } If 
> ($self->TicketObj->Status eq ?resolved?) { return 1; } Return 0;
>
> Custom action commit code:
> $self->TicketObj->SetStatus(?open?);
> ----------------------------------------
> On my test system it works perfectly. Any tickets resolved or rejected 
> get re-opened on correspond. On my production box, I get the following 
> in ym log:
>
> [13641] [Fri Aug 12 17:43:44 2016] [debug]: Skipping Scrip #32 because 
> it didn't Prepare (/opt/rt4/sbin/../lib/RT/Scrips.pm:345)
>
> I?ve tried writing my own messages to the log but it doesn?t look like 
> the scrip is firing. What is happening?
>
> *Stephen Cena*
> Senior Systems Administrator
> Quality Vision International, Inc.
> Phone: (585) 544-0450 x300
> To notify helpdesk: http://helpdesk.ogp.qvii.com or email:
> _hd-general at qvii.com_ <mailto:hd-general at qvii.com> To report email 
> issues: postmaster at qvii.com
>
>
>
>
>
> ---------
> RT 4.4 and RTIR Training Sessions https://bestpractical.com/training
> * Los Angeles - September, 2016
>

Stephen Cena
Senior Systems Administrator 
Quality Vision International, Inc.
Phone: (585) 544-0450 x300
To notify helpdesk: http://helpdesk.ogp.qvii.com or email: hd-general at qvii.com
To report email issues: postmaster at qvii.com



More information about the rt-users mailing list