Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the XML-MyXML CPAN distribution.

Report information
The Basics
Id: 26845
Status: rejected
Worked: 20 min
Priority: 0/
Queue: XML-MyXML

People
Owner: Nobody in particular
Requestors:
Cc:
AdminCc:

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



Subject: ML::MyXML + SOAP::Amazon::S3 bug
SOAP::Amazon::S3 not working cause of incompatible implementations of simple_to_xml http://search.cpan.org/src/KARJALA/SOAP-Amazon-S3-0.023/lib/SOAP/Amazon/ S3.pm In SOAP::Amazon::S3 you can see: Show quoted text
> use XML::MyXML 0.052 qw(tidy_xml simple_to_xml xml_to_object);
Show quoted text
> push @params, ( 'AWSAccessKeyId' => $self->{'access_key_id'} ); > push @params, ( 'Timestamp' => $timestamp ); > push @params, ( 'Signature' => $signature );
Show quoted text
> my $xml_body = simple_to_xml(\@params);
i.e. it is array with 3 elements 0.052 implementation of XML::MyXML works ok Show quoted text
> sub simple_to_xml { > my $arref = shift; > if ($arref eq 'XML::MyXML') { $arref = shift; } > > my $xml = ''; > > while (@$arref) { > my $key = shift @$arref;
lastest version can't work with 3 element arrays: Show quoted text
> sub simple_to_xml { > my $arref = shift; > my $flags = shift || {};
Show quoted text
> my $xml = ''; > my ($key, $value, @residue) = (ref $arref eq 'HASH') ? %$arref :
@$arref; Show quoted text
> Encode::_utf8_off($key); > if (@residue) { confess "Error: the provided simple ref contains
more than 1 top element"; } Show quoted text
> my ($tag) = $key =~ /^(\S+)/g; > confess "Error: Strange key: $key" if ! defined $tag;
@residue will always contain rest of array
This was a bug of SOAP-Amazon-S3, which was using an undocumented feature of XML::MyXML. SOAP-Amazon-S3 has just been fixed to work properly with the new version of XML::MyXML.