[rt-users] Can't load UntouchedInHours module

Elliott, Kevin C (DOR) kevin.elliott at alaska.gov
Thu Aug 29 13:39:33 EDT 2013


I'm working with Request Tracker 4.0.7 on Debian Wheezy 7.0.1 and am attempting to configure rt-crontool and UntouchedInHours.pm as presented on the Wiki (http://requesttracker.wikia.com/wiki/UntouchedInHours)

I'm running the following rt-crontool command:

/usr/bin/rt-crontool \
--search RT::Search::FromSQL  \
--search-arg "Queue = '1' AND (Status = 'new' OR Status = 'open' ) AND Owner != 'Nobody'" \
--condition RT::Condition::UntouchedInHours --condition-arg 4 \
--action RT::Action::SendEmail \
--template "Custom - Untouched Ticket Notification" \
--transaction 'last' \
--transaction-type 'Correspond,Comment,Status' \
--verbose echo ""



Which returns the following result:

[Thu Aug 29 17:32:17 2013] [critical]: Failed to load module RT::Condition::UntouchedInHours. () at /usr/bin/rt-crontool line 307. (/usr/share/request-tracker4/lib/RT.pm:351)
Failed to load module RT::Condition::UntouchedInHours. () at /usr/bin/rt-crontool line 307.



I'm taking that to mean that there is a programming pub in UntouchedInHours.pm that is preventing it from being called correctly but for the life of me I can't seem to find it anywhere. It was copied verbatim from the Wiki:

root at DorJnuASD-RT:~/Bin# cat /usr/share/request-tracker4/lib/RT/Condition/UntouchedInHours.pm                                                                                                                                               

package RT::Condition::UntouchedInHours;
require RT::Condition::Generic;

 use RT::Date;


 @ISA = qw(RT::Condition::Generic);


 use strict;
 use vars qw/@ISA/;

 sub IsApplicable {
         my $self = shift;

                 if ((time()-$self->TicketObj->LastUpdatedObj->Unix)/3600 >= $self->Argument) {
                        return 1;
                 }
                 else {
                        return 0;
                }

 }

 # The following could be omitted. They're there to allow overrides from Vendor and Local
 # but as this isn't a core module, they're just there for completeness :)
 eval "require RT::Condition::UntouchedInHours_Vendor";
 die $@ if ($@ && $@ !~ qr{^Can't locate RT/Condition/UntouchedInHours_Vendor.pm});
 eval "require RT::Condition::UntouchedInHours_Local";
 die $@ if ($@ && $@ !~ qr{^Can't locate RT/Condition/UntouchedInHours_Local.pm});

 1;



The permissions look appropriate as well:

root at DorJnuASD-RT:~/Bin# ls -la /usr/share/request-tracker4/lib/RT/Condition/
total 60
drwxr-xr-x  2 root root 4096 Aug 29 09:24 .
drwxr-xr-x 17 root root 4096 Jun 11 11:27 ..
-rw-r--r--  1 root root 2247 May 22 09:49 AnyTransaction.pm
-rw-r--r--  1 root root 2742 May 22 09:49 BeforeDue.pm
-rw-r--r--  1 root root 2677 May 22 09:49 CloseTicket.pm
-rw-r--r--  1 root root 2475 May 22 09:49 Overdue.pm
-rw-r--r--  1 root root 2351 May 22 09:49 OwnerChange.pm
-rw-r--r--  1 root root 2356 May 22 09:49 PriorityChange.pm
-rw-r--r--  1 root root 2325 May 22 09:49 PriorityExceeds.pm
-rw-r--r--  1 root root 2306 May 22 09:49 QueueChange.pm
lrwxrwxrwx  1 root root    9 Aug 29 08:37 RCS -> /root/RCS
-rw-r--r--  1 root root 2829 May 22 09:49 ReopenTicket.pm
-rw-r--r--  1 root root 4593 May 22 09:49 StatusChange.pm
-rw-r--r--  1 root root  800 Aug 29 09:23 UntouchedInHours.pm
-rw-r--r--  1 root root 2458 May 22 09:49 UserDefined.pm



Any idea what I'm missing here? Thanks.


---
Kevin Elliott
Networking Specialist II
Alaska Department of Revenue, ASD-IT
(907) 465-2314





More information about the rt-users mailing list