Skip Menu |

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

Report information
The Basics
Id: 35692
Status: resolved
Priority: 0/
Queue: RT-Client-REST

People
Owner: DAMS [...] cpan.org
Requestors: florian.dufour [...] inria.fr
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.35
Fixed in: (no value)



Subject: RT::Client::REST::_submit doesn't update HTTP::Message object $res
Hi, RT::Client::REST::_submit seems to have been broken since 0.35 : $res content is not updated as $res->decoded_content($text) doesn't SET the content (see HTTP::Message documentation). The content is then unmodified, which means that the first lines (RT status code) are not deleted. We should use $res->content($text) instead (that's the case in 0.34) ; however it doesn't work either as $text seems to be in Perl's internal form and not in bytes form (as it has to be for content()). That's why we have to use Encode::encode. Here is the patch for RT/Client/REST.pm : 499c499 < $res->decoded_content($text); --- Show quoted text
> $res->content(Encode::encode("utf8", $text));
I'm not sure it works if the RT website is not encoded in utf-8. Thanks for this distribution ! * Distribution name : RT-Client-REST-0.35 * Perl version : This is perl, v5.10.0 built for i486-linux-gnu-thread-multi * OS : Linux novembre 2.6.24-1-686 #1 SMP Thu Mar 27 17:45:04 UTC 2008 i686 GNU/Linux
From: florian.dufour [...] inria.fr
Woops ! Seems to be the same bug as #35146. Sorry ! Both tickets should be merged.
duplicate of 35146