Error with ModifyUsers.html after upgrade from 3.8.7 to 4.0.0

Hi,

At UMBC, we recently upgraded our development RT instance from 3.8.7 to
4.0.0. The upgrade went smoothly, but now when we open any ticket and
click on the “People” tab, we are getting the following error:

System error
error: Can’t use an undefined value as an ARRAY reference at
/local/rt4/share/html/Ticket/ModifyPeople.html line 115, line 12.
context:

111: for my $type (qw(To Cc Bcc)) {
112: $recips{$->address} = 1 for $scrip->ActionObj->Action->$type();
113: }
114: }
115: for my $rule (map {@{$
->Rules}} @txns) {
116: next unless $rule->{hints} && $rule->{hints}{class} eq “SendEmail”;
117: for my $type (qw(To Cc Bcc)) {
118: $recips{$_} = 1 for @{$rule->{hints}{recips}{$type}};
119: }

code stack: /local/rt4/share/html/Ticket/ModifyPeople.html:115
/local/rt4/sbin/…/lib/RT/Interface/Web.pm:522
/local/rt4/sbin/…/lib/RT/Interface/Web.pm:271
/local/rt4/share/html/autohandler:53

It appears that this is because ‘Rules’ is undefined for one or more of
the transactions in the @txns array, and the map statement is attempting
to dereference an undefined value. To confirm, I tried replacing line
115 with:

for my $rule (map {@{$->Rules}} grep(($->Rules != undef), @txns)) {

This fixed the error, and the result is a “modify people” page that
appears correct at first glance. However, it’s obviously a band-aid,
and not really knowing anything about RT internals, I’m worried that we
have a deeper systemic issue that’s going to crop up elsewhere. Any
ideas what would cause ‘Rules’ to be undefined in one or more of the
transactions here? It’s obviously not supposed to be undefined, or
presumably the code would already check for it.

Thanks for any insight!
Paul Riddle

Hi,

At UMBC, we recently upgraded our development RT instance from 3.8.7
to 4.0.0. The upgrade went smoothly, but now when we open any
ticket and click on the “People” tab, we are getting the following
error:

Paul,

Thanks for the report. This isn’t something I’ve seen before.

Did you install RT4 on top of your RT3 instance? At a first guess, this
could be mixing code from an RT3 customization or extension.

-Jesse