[ https://issues.apache.org/jira/browse/DAFFODIL-2124?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Michael Beckerle updated DAFFODIL-2124: --------------------------------------- Component/s: Unparsing Back End > Error unparsing bigInts > ----------------------- > > Key: DAFFODIL-2124 > URL: https://issues.apache.org/jira/browse/DAFFODIL-2124 > Project: Daffodil > Issue Type: Bug > Components: Back End, Unparsing > Reporter: Brandon Sloane > Assignee: Josh Adams > Priority: Major > Attachments: a.bin.xml, a.dfdl.xsd > > > On unparse, daffodil appears to try parsing numeric strings as a long > regardless of the bit length, potentiall causing issues when length>64. > Example attached. > > !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! > !! An unexpected exception occurred. This is a bug! !! > !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! > Please report this bug and help us fix it: > https://daffodil.apache.org/community/#issue-tracker > Please include the following exception, the command you > ran, and any input, schema, or tdml files used that led > to this bug. > java.lang.NumberFormatException: For input string: "7089904312036126320" > at > java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) > at java.lang.Integer.parseInt(Integer.java:583) > at java.lang.Integer.parseInt(Integer.java:615) > at scala.collection.immutable.StringLike.toInt(StringLike.scala:301) > at scala.collection.immutable.StringLike.toInt$(StringLike.scala:301) > at scala.collection.immutable.StringOps.toInt(StringOps.scala:29) > at > org.apache.daffodil.dpath.NodeInfo$PrimType$Int$.fromXMLString(NodeInfo.scala:459) > at > org.apache.daffodil.dpath.NodeInfo$PrimType$Int$.fromXMLString(NodeInfo.scala:457) > at > org.apache.daffodil.infoset.InfosetInputter.createElement(InfosetInputter.scala:347) > at > org.apache.daffodil.infoset.InfosetInputter.handleStartElement(InfosetInputter.scala:242) > at > org.apache.daffodil.infoset.InfosetInputter.reallyFill(InfosetInputter.scala:226) > at > org.apache.daffodil.infoset.InfosetInputter.fill(InfosetInputter.scala:213) > at org.apache.daffodil.util.CursorImplMixin.doAdvance(Cursor.scala:174) > at org.apache.daffodil.util.CursorImplMixin.advance(Cursor.scala:144) > at org.apache.daffodil.util.CursorImplMixin.advance$(Cursor.scala:141) > at > org.apache.daffodil.infoset.InfosetInputter.advance(InfosetInputter.scala:53) > at > org.apache.daffodil.processors.unparsers.UStateMain.advance(UState.scala:482) > at org.apache.daffodil.util.Cursor.advanceMaybe(Cursor.scala:104) > at org.apache.daffodil.util.Cursor.advanceMaybe$(Cursor.scala:103) > at > org.apache.daffodil.processors.unparsers.UState.advanceMaybe(UState.scala:72) > at > org.apache.daffodil.processors.unparsers.UStateMain.advanceOrError(UState.scala:499) > at > org.apache.daffodil.processors.unparsers.RegularElementUnparserStartEndStrategy.unparseBegin(ElementUnparser.scala:382) > at > org.apache.daffodil.processors.unparsers.RegularElementUnparserStartEndStrategy.unparseBegin$(ElementUnparser.scala:377) > at > org.apache.daffodil.processors.unparsers.ElementSpecifiedLengthUnparser.unparseBegin(ElementUnparser.scala:264) > at > org.apache.daffodil.processors.unparsers.ElementUnparserBase.unparse(ElementUnparser.scala:178) > at > org.apache.daffodil.processors.unparsers.Unparser.unparse1(Unparser.scala:72) > at > org.apache.daffodil.processors.unparsers.Unparser.unparse1$(Unparser.scala:39) > at > org.apache.daffodil.processors.unparsers.CombinatorUnparser.unparse1(Unparser.scala:128) > at org.apache.daffodil.processors.DataProcessor.doUnparse(Runtime.scala:356) > at org.apache.daffodil.processors.DataProcessor.unparse(Runtime.scala:304) > at org.apache.daffodil.Main$.$anonfun$run$14(Main.scala:1133) > at org.apache.daffodil.util.Timer$.getTimeResult(Timer.scala:76) > at org.apache.daffodil.util.Timer$.getResult(Timer.scala:35) > at org.apache.daffodil.Main$.run(Main.scala:1133) > at org.apache.daffodil.Main$.main(Main.scala:1361) > at org.apache.daffodil.Main.main(Main.scala) > > -- This message was sent by Atlassian JIRA (v7.6.3#76005)