Skip Menu |

This queue is for tickets about the RT-Client-REST CPAN distribution.

Report information
The Basics
Id: 85889
Status: rejected
Priority: 0/
Queue: RT-Client-REST

People
Owner: DMITRI [...] cpan.org
Requestors: tjwiley [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: Wishlist
Broken in: (no value)
Fixed in: (no value)



Subject: Case Sensitivity
Date: Wed, 5 Jun 2013 08:40:45 -0700
To: bug-RT-Client-REST [...] rt.cpan.org
From: "Timothy J. Wiley" <tjwiley [...] gmail.com>
For quite a few years, a bug has existed in RT::Client::REST that causes custom field not to be set upon ticket creation. It was reported on cpanforum.com, but I'm pretty sure it was never reported to any kind of bug tracker. I'm gonna be that guy that reports it to you formally. Below is a decent description of what's going on. From: http://cpanforum.com/threads/5808 --------------------------------------- "I don't know if this has been brought up, but I will continue with this post. I have been working on a perl script which will create a ticket in RT using REST. I started using RT::Client::REST 0.31. One of the requirements was the ability populate custom fields on ticket creation. Also needed the ticket to contain all the information it needed from a form on ticket creation. I used RT::Client::REST->create subroutine to create the ticket which was great as I could populate all fields on creation, except for custom fields. Why was this happening? Well, in REST.pm, it takes all the values provided in the hash in the create subroutine and makes them all lowercase. Custom fields need to start with "CF-" and in that case for them to work." --------------------------------------- And below I've even submitted a patch (to 0.43) to finally fix it. Admittedly, I don't know if it will break anything else, it certainly hasn't for us. --- RT/Client/REST.pm.orig 2012-01-09 10:09:51.000000000 -0800 +++ RT/Client/REST.pm 2013-06-03 12:48:17.000000000 -0700 @@ -318,7 +318,7 @@ my %set; if (defined(my $set = delete($opts{set}))) { while (my ($k, $v) = each(%$set)) { - vpush(\%set, lc($k), $v); + vpush(\%set, $k, $v); } } if (defined(my $text = delete($opts{text}))) {
Thank you -- I will double-check your results and apply the patch if things are OK.
On Wed Jun 05 11:41:00 2013, tjwiley@gmail.com wrote: Show quoted text
> Why was this happening? Well, in REST.pm, it takes all the values > provided in the hash in the create subroutine and makes them all > lowercase. Custom fields need to start with "CF-" and in that case for > them to work."
Which version of rt are you using? RT::Client::REST 0.48 works as intended with rt 4.2.3.
Subject: Re: [rt.cpan.org #85889] Case Sensitivity
Date: Sun, 4 May 2014 12:07:18 -0700
To: bug-RT-Client-REST [...] rt.cpan.org
From: "Timothy J. Wiley" <tjwiley [...] gmail.com>
I can't guarantee which version we were on in June, but we're currently on 4.0.13. At the time we were also using version 0.43 of RT::Client::REST, so this bug may be safe to close. If it comes up again, I'll reopen it. On Sun, May 4, 2014 at 11:57 AM, Dmitri Tikhonov via RT < bug-RT-Client-REST@rt.cpan.org> wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=85889 > > > On Wed Jun 05 11:41:00 2013, tjwiley@gmail.com wrote:
> > Why was this happening? Well, in REST.pm, it takes all the values > > provided in the hash in the create subroutine and makes them all > > lowercase. Custom fields need to start with "CF-" and in that case for > > them to work."
> > Which version of rt are you using? RT::Client::REST 0.48 works as > intended with rt 4.2.3. >
On Sun May 04 15:07:27 2014, tjwiley@gmail.com wrote: Show quoted text
> I can't guarantee which version we were on in June, but we're currently on > 4.0.13. At the time we were also using version 0.43 of RT::Client::REST, > so this bug may be safe to close. If it comes up again, I'll reopen it.
I cannot reproduce this issue with 4.0.18 (rt.cpan.org -- I used examples/edit_custom_field.pl to set Severity), either. I tried RT::Client::REST 0.48 and 0.43. I'll have to change it to "rejected" -- I think this is the right status under the circumstances. Please do file another one if you see this again. Thanks for your report.