You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@daffodil.apache.org by "Dave Thompson (Jira)" <ji...@apache.org> on 2020/06/08 09:39:00 UTC

[jira] [Closed] (DAFFODIL-2124) Error unparsing bigInts

     [ https://issues.apache.org/jira/browse/DAFFODIL-2124?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dave Thompson closed DAFFODIL-2124.
-----------------------------------

Verified the specified commit (actually commit 2de4ea13757d50d8dbfeed0666cb62ffd2710b71) is included in the latest pull from the incubator-daffodil repository.

Verified the dfd-schema repository sbt tests execute successfully.

Verified the effected incubator-daffodil sbt test suites execute successfully.

Verified the nightly test schemas compile and save successfully.

Verified the nightly test suite executes successfully.

> 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
>            Priority: Major
>             Fix For: 3.0.0
>
>         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
(v8.3.4#803005)