Autoreply to new requestors

I have a scrip that, when a ticket is created by email by under certain
conditions, will delete the email sender as the requestor and replace it
with a different requestor (in order to permit creating tickets on behalf of
others). I have confirmed this scrip works properly, and that this scrip
executes prior to the default scrip which autoreplies to ticket creators.
Yet, the autoreply is being sent to the email sender and not to the new
requestor. Does anyone have a suggestion to ensure the autoreply is sent to
the newly-set requestor and not the email sender?

-Abe

View this message in context: http://requesttracker.8502.n7.nabble.com/Autoreply-to-new-requestors-tp56239.html

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1On 1/10/14, 12:17 PM, Abraham Liebsch wrote:

I have a scrip that, when a ticket is created by email by under
certain conditions, will delete the email sender as the requestor
and replace it with a different requestor (in order to permit
creating tickets on behalf of others). I have confirmed this scrip
works properly, and that this scrip executes prior to the default
scrip which autoreplies to ticket creators. Yet, the autoreply is
being sent to the email sender and not to the new requestor. Does
anyone have a suggestion to ensure the autoreply is sent to the
newly-set requestor and not the email sender?

Is the Autoreply scrip before or after the replace-the-requestor scrip?

Best,

  • –Glenn
    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v1.4.9 (Darwin)
    Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iEYEARECAAYFAlLQMNkACgkQf5MxTDXTimFVegCfUqnGPBGfytg9wTziYNGZft4o
6pYAmgKS82cMFgwjFnn46iDubwRZ7fIw
=76uH
-----END PGP SIGNATURE-----

It appears to be running afterwards. I’ve renamed the scripts, prepending
100 to the reassignment scrip and 110 to the autoreply scrip, so that they
are listed in the proper order, and confirmed in the apache log that the
requestors are changed before the autoreply scrip is run. Unless there is
an order-of-execution nuance that escapes me, it appears that the requestor
is replaced first. I could be missing something, though, as there is
another scrip that, according to the log, is executing between those two,
despite not being listed between them.From: rt-users-bounces@lists.bestpractical.com
[mailto:rt-users-bounces@lists.bestpractical.com] On Behalf Of Glenn Sieb
Sent: Friday, January 10, 2014 11:42 AM
To: rt-users@lists.bestpractical.com
Subject: Re: [rt-users] Autoreply to new requestors

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

smime.p7s (5.91 KB)

It appears to be running afterwards. I’ve renamed the scripts, prepending
100 to the reassignment scrip and 110 to the autoreply scrip, so that they
are listed in the proper order, and confirmed in the apache log that the
requestors are changed before the autoreply scrip is run. Unless there is
an order-of-execution nuance that escapes me, it appears that the requestor
is replaced first. I could be missing something, though, as there is
another scrip that, according to the log, is executing between those two,
despite not being listed between them.

The Autoreply scrip is most likely executing on a cached copy of the
ticket (it doesn’t reload the ticket between scrip executions).

Probably the simplest thing to do is to make the Autoreply scrip
execute in the Transaction Batch stage. Since it’s an On Create
action, any problems should be minimal.

-kevin

I just wanted to follow-up and let you know that this fixed my issue.
Thanks!From: rt-users-bounces@lists.bestpractical.com
[mailto:rt-users-bounces@lists.bestpractical.com] On Behalf Of Kevin Falcone
Sent: Wednesday, January 15, 2014 10:04 AM
To: rt-users@lists.bestpractical.com
Subject: Re: [rt-users] Autoreply to new requestors

It appears to be running afterwards. I’ve renamed the scripts,
prepending
100 to the reassignment scrip and 110 to the autoreply scrip, so that
they are listed in the proper order, and confirmed in the apache log
that the requestors are changed before the autoreply scrip is run.
Unless there is an order-of-execution nuance that escapes me, it
appears that the requestor is replaced first. I could be missing
something, though, as there is another scrip that, according to the
log, is executing between those two, despite not being listed between
them.

The Autoreply scrip is most likely executing on a cached copy of the ticket
(it doesn’t reload the ticket between scrip executions).

Probably the simplest thing to do is to make the Autoreply scrip execute in
the Transaction Batch stage. Since it’s an On Create action, any problems
should be minimal.

-kevin

-----Original Message-----
From: rt-users-bounces@lists.bestpractical.com
[mailto:rt-users-bounces@lists.bestpractical.com] On Behalf Of Glenn
Sieb
Sent: Friday, January 10, 2014 11:42 AM
To: rt-users@lists.bestpractical.com
Subject: Re: [rt-users] Autoreply to new requestors

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

I have a scrip that, when a ticket is created by email by under
certain conditions, will delete the email sender as the requestor
and replace it with a different requestor (in order to permit
creating tickets on behalf of others). I have confirmed this scrip
works properly, and that this scrip executes prior to the default
scrip which autoreplies to ticket creators. Yet, the autoreply is
being sent to the email sender and not to the new requestor. Does
anyone have a suggestion to ensure the autoreply is sent to the
newly-set requestor and not the email sender?

Is the Autoreply scrip before or after the replace-the-requestor scrip?

smime.p7s (5.91 KB)