My favorites | Sign in
Project Home Downloads Wiki Issues Source
READ-ONLY: This project has been archived. For more information see this post.
Search
for
  Advanced search   Search tips   Subscriptions
Issue 7: EmptyStackException and ArrayIndexOutOfBoundsException when calling getLineItemsByStatement
2 people starred this issue and may be notified of changes. Back to list
Status:  Invalid
Owner:  ----
Closed:  Mar 2012


 
Reported by darren.y...@redfin.com, Mar 26, 2012
What steps will reproduce the problem?
LineItemServiceInterface lisi = services.get(session, LineItemServiceInterface.class);
String lineItemsQuery = "WHERE name = '" + lineItemName + "' AND status = 'DELIVERING' LIMIT 500";
Statement lineItemsStatement = new Statement();
lineItemsStatement.setQuery(lineItemsQuery);
LineItemPage lineItemPage = lisi.getLineItemsByStatement(lineItemsStatement); 

The exception is thrown on the last line when I call 'lisi.getLineItemByStatement'

What is the expected output? What do you see instead?
I expect to see no errors.

Instead I see the following exceptions being thrown:

An unexpected error reached JSONErrorHandlerExceptionResolver java.util.EmptyStackException
        at java.util.Stack.peek(Stack.java:85)
        at java.util.Stack.pop(Stack.java:67)
        at org.apache.xml.serializer.NamespaceMappings.popNamespace(NamespaceMappings.java:203)
        at org.apache.xml.serializer.NamespaceMappings.popNamespaces(NamespaceMappings.java:264)
        at org.apache.xml.serializer.ToStream.endElement(ToStream.java:1977)
        at org.apache.xalan.transformer.TransformerIdentityImpl.endElement(TransformerIdentityImpl.java:1101)
        at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
        at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl $FragmentContentDispatcher.dispatch(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
        at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
        at org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:484)
        at com.google.api.ads.common.lib.utils.logging.PrettyPrinter.prettyPrint(com.google.api.ads.common.lib.utils.logging.PrettyPrinter:69)
        at com.google.api.ads.common.lib.utils.logging.AdsServiceLoggers.logSoapXml(com.google.api.ads.common.lib.utils.logging.AdsServiceLoggers:81)
        at com.google.api.ads.common.lib.client.AdsServiceClient.logSoapCall(com.google.api.ads.common.lib.client.AdsServiceClient:93)
        at com.google.api.ads.common.lib.soap.SoapServiceClient.invoke(com.google.api.ads.common.lib.soap.SoapServiceClient:95)
        at $Proxy141.getLineItemsByStatement(Unknown Source) 

AND

An unexpected error reached JSONErrorHandlerExceptionResolver java.lang.ArrayIndexOutOfBoundsException: Attempt to modify attribute at illegal index: 1
        at org.xml.sax.helpers.AttributesImpl.badIndex(AttributesImpl.java:603)
        at org.xml.sax.helpers.AttributesImpl.setValue(AttributesImpl.java:549)
        at org.apache.xml.serializer.ToStream.addAttributeAlways(ToStream.java:2759)
        at org.apache.xml.serializer.ToStream.ensurePrefixIsDeclared(ToStream.java:2666)
        at org.apache.xml.serializer.ToStream.startElement(ToStream.java:1744)
        at org.apache.xalan.transformer.TransformerIdentityImpl.startElement(TransformerIdentityImpl.java:1072)
        at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
        at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl $FragmentContentDispatcher.dispatch(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
        at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
        at org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:484)
        at com.google.api.ads.common.lib.utils.logging.PrettyPrinter.prettyPrint(com.google.api.ads.common.lib.utils.logging.PrettyPrinter:69)
        at com.google.api.ads.common.lib.utils.logging.AdsServiceLoggers.logSoapXml(com.google.api.ads.common.lib.utils.logging.AdsServiceLoggers:79)
        at com.google.api.ads.common.lib.client.AdsServiceClient.logSoapCall(com.google.api.ads.common.lib.client.AdsServiceClient:93)
        at com.google.api.ads.common.lib.soap.SoapServiceClient.invoke(com.google.api.ads.common.lib.soap.SoapServiceClient:95)
        at $Proxy141.getLineItemsByStatement(Unknown Source)

What version of the product are you using? On what operating system?
v201111 on Windows 7 and Ubuntu 11.10

Please provide any additional information below.


Mar 26, 2012
Project Member #1 aro...@google.com
Hi Darren,

Can you please file this bug against the correct project: https://code.google.com/p/google-api-ads-java/issues/list

This is issue tracker is for the old library. It looks like you are using the new one.

Thanks,
Adam
Status: Invalid

Powered by Google Project Hosting