Error in XML-RPC call Bug.get_bugs on Bugzilla 3.0 & 3.2.

View: New views
2 Messages — Rating Filter:   Alert me  

Error in XML-RPC call Bug.get_bugs on Bugzilla 3.0 & 3.2.

by Tom Parker-19 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

I am able to call Bug.get_bugs via the Bugzilla web services API on an
instance of Bugzilla 3.4, but the same call fails for both 3.0 & 3.2. I need
to make it work for a 3.0 installation where upgrading Bugzilla is currently
not an option. I have searched for a solution for the past few hours, but no
luck so far.

Some more details. My XML-RPC code is in Objective C, and I am passing an
array (NSArray) of dictionary (NSDictionary) objects. NSDictionary is like a
has/map which is what the Bugzilla API expects, and it works great for 3.4,
but when running against 3.0, I get the following error:

*Fault string: Can't use string ("76") as an ARRAY ref while "strict refs"
in use at Bugzilla/WebService/Bug.pm line 69.*

*
*

This is the XML-RPC request that I send:


**
*

<?xml
version="1.0"?><methodCall><methodName>Bug.get_bugs</methodName><params><param><value><struct><member><name>ids</name><value><i4>76</i4></value></member></struct></value></param></params></methodCall>


I have also tried using <int>76</int>, in place of <i4>76</i4> above, but
that didn't help.


This error is reproducible with the Bugzilla 3.0 instance running at:

https://landfill.bugzilla.org/bugzilla-3.0-branch/


Thanks in advance for any help!


Tom.
*
_______________________________________________
support-bugzilla mailing list
support-bugzilla@...
https://lists.mozilla.org/listinfo/support-bugzilla
PLEASE put support-bugzilla@... in the To: field when you reply.

Re: Error in XML-RPC call Bug.get_bugs on Bugzilla 3.0 & 3.2.

by Max Kanat-Alexander :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On 11/05/2009 11:13 PM, Tom Parker wrote:
> *Fault string: Can't use string ("76") as an ARRAY ref while "strict refs"
> in use at Bugzilla/WebService/Bug.pm line 69.*

        You are using a call format that Bugzilla 3.0 does not understand. Your
argument for Bugzilla 3.0 must look like this:

        { ids => [1] }

        Note that ids points to an array.

        -Max
--
http://www.everythingsolved.com/
Competent, Friendly Bugzilla and Perl Services. Everything Else, too.
_______________________________________________
support-bugzilla mailing list
support-bugzilla@...
https://lists.mozilla.org/listinfo/support-bugzilla
PLEASE put support-bugzilla@... in the To: field when you reply.