RT_System opening tickets?

Hey there, I’m running RT 2.0.9, and for some reason, after a ticket is
closed, sometimes RT_System opened it up. A co-worker noticed it and
asked me why it happened, and I didn’t know. Then it happened to one of
my tickets.

anyone else had this function?

Sheeri Kritzer
Systems Administrator
University Systems Group
Tufts University
617-627-3925
sheeri.kritzer@tufts.edu

RT automatically opens tickets when you start doing things
like adding new updates to them. (And yes, in the distant future, this
should all be done with Scrips, rather than hard-coded)On Fri, Jan 11, 2002 at 10:49:39AM -0500, Sheeri Kritzer wrote:

Hey there, I’m running RT 2.0.9, and for some reason, after a ticket is
closed, sometimes RT_System opened it up. A co-worker noticed it and
asked me why it happened, and I didn’t know. Then it happened to one of
my tickets.

anyone else had this function?


Sheeri Kritzer
Systems Administrator
University Systems Group
Tufts University
617-627-3925
sheeri.kritzer@tufts.edu


rt-users mailing list
rt-users@lists.fsck.com
http://lists.fsck.com/mailman/listinfo/rt-users

http://www.bestpractical.com/products/rt – Trouble Ticketing. Free.

Usually that’s as a result of somebody replying to the ticket after it was
closed.
RT will reopen a ticket if there’s correspondance going on.

-fr.

At 15:49 11/01/02, Sheeri Kritzer wrote:

Hey there, I’m running RT 2.0.9, and for some reason, after a ticket is
closed, sometimes RT_System opened it up. A co-worker noticed it and
asked me why it happened, and I didn’t know. Then it happened to one of
my tickets.

anyone else had this function?


Sheeri Kritzer
Systems Administrator
University Systems Group
Tufts University
617-627-3925
sheeri.kritzer@tufts.edu


rt-users mailing list
rt-users@lists.fsck.com
http://lists.fsck.com/mailman/listinfo/rt-users

Feargal Reilly,
Systems Administrator,
The CIA.

RT automatically opens tickets when you start doing things
like adding new updates to them. (And yes, in the distant future, this
should all be done with Scrips, rather than hard-coded)

OnCorrespond ReOpenTicket with template Blank ?

Hrm, would the following work (as RT::Action::ReOpenTicket) ?

( brief sideline in trying to stop from going mad on other matters )

                         Bruce Campbell                            RIPE
                                                                    NCC
                                                             Operations

# Copyright guff - 2002  Bruce Campbell (bruce_campbell@ripe.net)
package RT::Action::ReOpenTicket;
require RT::Action::Generic;

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

=head1 NAME

RT::Action::ReOpenTicket - An Action to re-open a ticket if two
conditions are met - correspondence has come in, and the ticket
is marked as resolved.

=head1 SYNOPSIS

require RT::Action::ReOpenTicket;
@ISA = qw(RT::Action::ReOpenTicket);

=head1 DESCRIPTION

This only affects tickets which are resolved.  Tickets with any
other status stay that way.

Does not send email when this happens.  In Scrip terms, this is:

	OnCorrespond ReOpenTicket with template Blank

=begin testing

ok (require RT::TestHarness);
ok (require RT::Action::Generic);

=end testing

=head1 AUTHOR

Bruce Campbell <bruce_campbell@ripe.net>

=head1 SEE ALSO

perl(1), RT

=cut

# Prepare ourselves.  Check if this ticket is resolved.
sub Prepare {
	my $self = shift;

	my $retval = 0;
	if( $self->TicketObj ){
		if( $self->TicketObj->Status =~ /resolve/i ){
			$retval = 1;
		}
	}else{
		$RT::Logger->warning("No ticket object handed to $self\n");
	}
	return( $retval );
}

# Open the ticket.
sub Commit {

	my $self = shift;
	my $retval = 0;
	if( $self->TicketObj ){
		# Let this module be reused if we want to do something
		# else with it.
		my $action = $self->Argument || "open";

		# SetStatus takes care of current user etc.
		$retval = $self->TicketObj->SetStatus( $action );
	}else{
		$RT::Logger->warning("No ticket object handed to $self\n");
	}
	return( $retval );
}

Without running that code, yeah, it looks like it would work.On Fri, Jan 11, 2002 at 07:24:20PM +0100, Bruce Campbell wrote:

On Fri, 11 Jan 2002, Jesse Vincent wrote:

RT automatically opens tickets when you start doing things
like adding new updates to them. (And yes, in the distant future, this
should all be done with Scrips, rather than hard-coded)

OnCorrespond ReOpenTicket with template Blank ?

Hrm, would the following work (as RT::Action::ReOpenTicket) ?

( brief sideline in trying to stop from going mad on other matters )


Bruce Campbell RIPE
NCC
Operations

Copyright guff - 2002 Bruce Campbell (bruce_campbell@ripe.net)

package RT::Action::ReOpenTicket;
require RT::Action::Generic;

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

=head1 NAME

RT::Action::ReOpenTicket - An Action to re-open a ticket if two
conditions are met - correspondence has come in, and the ticket
is marked as resolved.

=head1 SYNOPSIS

require RT::Action::ReOpenTicket;
@ISA = qw(RT::Action::ReOpenTicket);

=head1 DESCRIPTION

This only affects tickets which are resolved. Tickets with any
other status stay that way.

Does not send email when this happens. In Scrip terms, this is:

  OnCorrespond ReOpenTicket with template Blank

=begin testing

ok (require RT::TestHarness);
ok (require RT::Action::Generic);

=end testing

=head1 AUTHOR

Bruce Campbell bruce_campbell@ripe.net

=head1 SEE ALSO

perl(1), RT

=cut

Prepare ourselves. Check if this ticket is resolved.

sub Prepare {
my $self = shift;

  my $retval = 0;
  if( $self->TicketObj ){
  	if( $self->TicketObj->Status =~ /resolve/i ){
  		$retval = 1;
  	}
  }else{
  	$RT::Logger->warning("No ticket object handed to $self\n");
  }
  return( $retval );

}

Open the ticket.

sub Commit {

  my $self = shift;
  my $retval = 0;
  if( $self->TicketObj ){
  	# Let this module be reused if we want to do something
  	# else with it.
  	my $action = $self->Argument || "open";

  	# SetStatus takes care of current user etc.
  	$retval = $self->TicketObj->SetStatus( $action );
  }else{
  	$RT::Logger->warning("No ticket object handed to $self\n");
  }
  return( $retval );

}

http://www.bestpractical.com/products/rt – Trouble Ticketing. Free.

Hello all,

The ticket will be reopened, great.
But take a look at this use case (common, at least here):

I resolve a case (I was the owner). 2 days later, I’m in holiday. The
Requestor reopens the ticket sending a mail, saying the problem is still
there.
The ticket is reopened (using you new Scrip or using the current
feature), but since it’s owned by someone that is in holliday… noone
in the help desk staff will receive a notification (provided I have a
Scrip that send an e-mail to the owner on correspondance).

The ticket will be reopened, great.
But take a look at this use case (common, at least here):

I resolve a case (I was the owner). 2 days later, I’m in holiday. The
Requestor reopens the ticket sending a mail, saying the problem is still
there.
The ticket is reopened (using you new Scrip or using the current
feature), but since it’s owned by someone that is in holliday… noone
in the help desk staff will receive a notification (provided I have a
Scrip that send an e-mail to the owner on correspondance).

From my point of view it’s not a simple issue…

Urm. You don’t have a scrip:

OnCorrespond NotifyAdminCcs with template Correspondence

?

That one (suggested by default) notifies all AdminCcs, irrespective of who
owns the ticket. At least in our situation, it would be very bad for our
ticketing system to only notify the Owners, particularly when the Owner
might not be checking email for the next month.

All that my suggestion does (or should do) is reopen the ticket if
required.

                         Bruce Campbell                            RIPE
               Systems/Network Engineer                             NCC
             www.ripe.net - PGP562C8B1B                      Operations

Hello,
Ye, I understand the purpose of your action (only reopening the ticket).

I our RT installation, I haven’t the scrip you suggested since I don’t
want every queue AdminCC be notified for every correspondance on every
ticket… If someone goes on holidays, he must reassign all his tickets
and receiving all the correspondance is not good for us. Suppose I
receive a mail notifying me of a new mail on a ticket that I don’t own.
How can I say “OK, it Bob’s ticket but he’s on holiday, I take the
correspondance?”. Somewhat complex and I think a lot of correspondance
would be lost…

In my configuration I have:

OnCreate NotifyAllWatchers…
OnCorrespondance NotifyOwner…

Rafael-----Original Message-----
From: Bruce Campbell [mailto:bruce_campbell@ripe.net]
Sent: mardi, 22. janvier 2002 16:22
To: Rafael Corvalan
Cc: RT Users
Subject: RE: [rt-users] RT_System opening tickets?

On Tue, 22 Jan 2002, Rafael Corvalan wrote:

The ticket will be reopened, great.
But take a look at this use case (common, at least here):

I resolve a case (I was the owner). 2 days later, I’m in holiday. The
Requestor reopens the ticket sending a mail, saying the problem is
still there. The ticket is reopened (using you new Scrip or using the
current feature), but since it’s owned by someone that is in
holliday… noone in the help desk staff will receive a notification
(provided I have a Scrip that send an e-mail to the owner on
correspondance).

From my point of view it’s not a simple issue…

Urm. You don’t have a scrip:

OnCorrespond NotifyAdminCcs with template Correspondence

?

That one (suggested by default) notifies all AdminCcs, irrespective of
who owns the ticket. At least in our situation, it would be very bad
for our ticketing system to only notify the Owners, particularly when
the Owner might not be checking email for the next month.

All that my suggestion does (or should do) is reopen the ticket if
required.

                         Bruce Campbell

RIPE
Systems/Network Engineer
NCC
www.ripe.net - PGP562C8B1B
Operations

Is RT meant to keep track of when people are on vacation? :slight_smile:

You could set up your e-mail client (or procmail, or whatever) with a
vacation rule that picks up any incoming mail from RT and forwards it to
someone else.

-----Original Message-----
From: Rafael Corvalan [mailto:Rafael.Corvalan@linkvest.com]
Sent: Tuesday, January 22, 2002 9:19 AM
To: Bruce Campbell
Cc: RT Users
Subject: RE: [rt-users] RT_System opening tickets?

Hello all,

The ticket will be reopened, great.
But take a look at this use case (common, at least here):

I resolve a case (I was the owner). 2 days later, I’m in holiday. The
Requestor reopens the ticket sending a mail, saying the
problem is still
there.
The ticket is reopened (using you new Scrip or using the current
feature), but since it’s owned by someone that is in holliday… noone
in the help desk staff will receive a notification (provided I have a
Scrip that send an e-mail to the owner on correspondance).
From my point of view it’s not a simple issue…

Any ideas?
Rafael

PS: In your code, the user that re-open the ticket is the
user that send
the correspondance isn’t it?. Am I wrong saying that this
user could not
the right to do so? (that’s why the current code to the
change using the
RT_System user?)

-----Original Message-----
From: Jesse Vincent [mailto:jesse@bestpractical.com]
Sent: vendredi, 11. janvier 2002 20:16
To: Bruce Campbell
Cc: RT Users
Subject: Re: [rt-users] RT_System opening tickets?

Without running that code, yeah, it looks like it would work.

RT automatically opens tickets when you start doing things like
adding new updates to them. (And yes, in the distant future, this
should all be done with Scrips, rather than hard-coded)

OnCorrespond ReOpenTicket with template Blank ?

Hrm, would the following work (as RT::Action::ReOpenTicket) ?

( brief sideline in trying to stop from going mad on other matters )


Bruce Campbell
RIPE

NCC

Operations

# Copyright guff - 2002  Bruce Campbell

(bruce_campbell@ripe.net)

package RT::Action::ReOpenTicket;
require RT::Action::Generic;

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

=head1 NAME

RT::Action::ReOpenTicket - An Action to re-open a ticket if two
conditions are met - correspondence has come in, and the ticket
is marked as resolved.

=head1 SYNOPSIS

require RT::Action::ReOpenTicket;
@ISA = qw(RT::Action::ReOpenTicket);

=head1 DESCRIPTION

This only affects tickets which are resolved.  Tickets with any
other status stay that way.

Does not send email when this happens.  In Scrip terms, this is:

  OnCorrespond ReOpenTicket with template Blank

=begin testing

ok (require RT::TestHarness);
ok (require RT::Action::Generic);

=end testing

=head1 AUTHOR

Bruce Campbell <bruce_campbell@ripe.net>

=head1 SEE ALSO

perl(1), RT

=cut

# Prepare ourselves.  Check if this ticket is resolved.
sub Prepare {
  my $self = shift;

  my $retval = 0;
  if( $self->TicketObj ){
  	if( $self->TicketObj->Status =~ /resolve/i ){
  		$retval = 1;
  	}
  }else{
  	$RT::Logger->warning("No ticket object handed to

$self\n");

  }
  return( $retval );
}

# Open the ticket.
sub Commit {

  my $self = shift;
  my $retval = 0;
  if( $self->TicketObj ){
  	# Let this module be reused if we want to do

something

  	# else with it.
  	my $action = $self->Argument || "open";

  	# SetStatus takes care of current user etc.
  	$retval = $self->TicketObj->SetStatus( $action

);

  }else{
  	$RT::Logger->warning("No ticket object handed to

$self\n");

  }
  return( $retval );
}


http://www.bestpractical.com/products/rt – Trouble Ticketing. Free.


rt-users mailing list
rt-users@lists.fsck.com
http://lists.fsck.com/mailman/listinfo/rt-users

rt-users mailing list
rt-users@lists.fsck.com
http://lists.fsck.com/mailman/listinfo/rt-users

Hello,
Ye, I understand the purpose of your action (only reopening the ticket).

I our RT installation, I haven’t the scrip you suggested since I don’t
want every queue AdminCC be notified for every correspondance on every
ticket… If someone goes on holidays, he must reassign all his tickets
and receiving all the correspondance is not good for us. Suppose I
receive a mail notifying me of a new mail on a ticket that I don’t own.
How can I say “OK, it Bob’s ticket but he’s on holiday, I take the
correspondance?”. Somewhat complex and I think a lot of correspondance
would be lost…

In my configuration I have:

OnCreate NotifyAllWatchers…
OnCorrespondance NotifyOwner…

Hrm. This is really a local administration issue, specific to your way of
doing things (ie, its not a problem with RT itself, just how you’ve got it
set up).

At the moment, you are depending on some external action (reassiging the
Owner) when someone goes on holiday. Fine, if it works, you’re home-free.
If it doesn’t (as these things normally don’t :wink: ), you’re in a bit of a
bind.

Assuming that you have a reliable system of detecting whether someone is
on holidays, you could do something like (replacing NotifyOwner):

OnCorrespond NotifyOwnerOrAllIfOnHols using template Correspondence

The intended behaviour is that if Correspondence comes in on a ticket
while the Owner is on holidays, all AdminCcs will get it, with the
assumption that one of these will Steal the Ticket away from the previous
Owner so your Customer keeps getting interaction.

( If they don’t Steal it away, then everyone will keep on getting the
Correspondence while the Owner is on holidays )

As for what NotifyOwnerOrAllIfOnHols does, I’d suggest copying Notify.pm,
putting the required code in SetReceipients(), and Bob’s your Auntie’s
Live-In Lover.

Code snippet for SetReceipients below, you have to write your own
IsOnHolidays() routine to put in the module.

Regards,

                         Bruce Campbell                            RIPE
               Systems/Network Engineer                             NCC
             www.ripe.net - PGP562C8B1B                      Operations

if ( ($arg =~ /\bOwner\b/) &&
     ($self->TicketObj->OwnerObj->id != $RT::Nobody->id) ) {
    my @additionals = ();
    if( $self->IsOnHolidays( $self->TicketObj->OwnerObj->EmailAddress ) ){
    # The owner is on holidays.  Notify everyone
    push(@additionals, @{$self->TicketObj->AdminCc->Emails});
    push(@additionals, @{$self->TicketObj->QueueObj->AdminCc->Emails});
}
    # If we're not sending to Ccs or requestors,
    # then the Owner can be the To.
    if (@To) {
        push(@Bcc, $self->TicketObj->OwnerObj->EmailAddress);
    push(@Bcc, @additionals) if( defined( @additionals ) );
    }
    else {
        push(@To, $self->TicketObj->OwnerObj->EmailAddress);
    push(@To, @additionals) if( defined( @additionals ) );
    }

Is RT meant to keep track of when people are on vacation? :slight_smile:

You could set up your e-mail client (or procmail, or whatever) with a
vacation rule that picks up any incoming mail from RT and forwards it to
someone else.

Thats no fun!

The other problem from our experience is that people may not set up a mail
filtering to actually forward the message onwards, or to autoreply when
they’re on holidays. Hence, our ticketing systems will mail all admins
for that queue, and not just the owner of the ticket.

As we have a personnel department, they keep track of holidays, and make
sure that the data is available in a parseable form; only thing we do with
said parseable data atm is run a web script over it :wink:

                         Bruce Campbell                            RIPE
               Systems/Network Engineer                             NCC
             www.ripe.net - PGP562C8B1B                      Operations