Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: First version.

...

  • check JIRA (to see if the bug is already reported)
  • create a TDML file for reproducing the bug/issue
  • create a JIRA ticket and attach your TDML
    OR
  • email the issue to daffodil-users@oss.tresys.com (you have to sign up for that list to be able to send to it.)

Details are below.

A TDML file is often useful just to ask a question about how something in DFDL works, for example, to get a clarification. It allows for a level of precision that is often lacking, but also often required when discussing complex data format issues.

Check JIRA to See if your Issue is Already There

First you should give a search of our JIRA tickets to see if the problem is already recorded.

...

Suppose you save the above out as a file "myDateTimeBug.tdml". You can then run it using the Daffodil command line tool:

Code Block
...tbd...
daffodil test myDateTimeBug.tdml

When specifying the test data, there are other ways to do this than using just text.

...

Code Block
    <tdml:document>

      <!--
          A document part with type="text" is text. Use CDATA to avoid whitespace changes.

          So in the example below, the line ending after '250;' and after '967;' are intentional
          parts of the data.
        -->

      <tdml:documentPart type="text"><![CDATA[quantity:250;
hardnessRating:967;
]]></tdml:documentPart>

      <!-- 
          In 'text' both XML character entities, and DFDL's own character entities are interpreted.

          So here is a NUL terminated string that contains a date with some Japanese Kanji characters.
          The Japanese characters are expressed using XML numeric character entities. The NUL termination
          is expressed using a DFDL character entity.

          In this example one has no choice but to use a DFDL character entity. The NUL character (which has character
          code zero), is not allowed in XML documents, not even using an XML character entity. So you 
          have to write '%NUL;' or '%#x00;' to express it using DFDL character entities.
        -->

      <tdml:documentPart type="text"><![CDATA[1987&#x5E74;10&#x6708;&#x65e5; BCE%NUL;]]></tdml:documentPart>

      <!--
          Type 'byte' means use hexadecimal to specify the data. Freeform whitespace is allowed. 
          Actually, any character that is not a-zA-Z0-9 is ignored. So you can use "." or "-" to separate
          groups of hex digits if you like.
       -->
 
      <tdml:documentPart type="byte">
            9Abf e4c3
            A5-E9-FF-00
      </tdml:documentPart>
      
       <!--
          Type 'bits' allows you to specify individual 0 and 1. Any character other than 0 or 1 is ignored.
           -->

         <tdml:documentPart type="bits">
            1.110 0.011 1101 First 5 bit fields.
 The number of bits does not have to be a multiple of 8. That is, whole bytes are not required.
        </ -->

       <tdml:documentPart type="bits">
            1.110 0.011 1 First 5 bit fields.
       </tdml:documentPart>

       <!--
          Type 'file' means the content is a file name where to get the data
         -->
  
       <tdml:documentPart type="file">/some/directory/testData.in<in.dat</tdml:documentPart>

    </tdml:document>

 

 

Finally, here's an example that uses Unicode characters :

...

Further details on TDML will go in a more detailed guide/page about writing TDML.

If you use the external schema file or external data file capabilities, then of course you need to send those files along with your TDML.