W3C home > Mailing lists > Public > xproc-dev@w3.org > August 2010

[Fwd: XD0016 Error] - retry

From: Betty Harvey <harvey@eccnet.com>
Date: Thu, 12 Aug 2010 12:33:57 -0400 (EDT)
Message-ID: <3953.208.54.35.91.1281630837.squirrel@www.eccnet.com>
To: xproc-dev@w3.org

---------------------------- Original Message ----------------------------
Subject: XD0016 Error
From:    "Betty Harvey" <harvey@eccnet.com>
Date:    Tue, August 10, 2010 12:09 pm
To:      xproc-dev@w3.org
--------------------------------------------------------------------------

I am using Calabash in Oxygen.  I am getting the following error:

Description: XD0016 : XD0016 It is a dynamic error if the select
expression on a p:input returns atomic values or anything other than
element or document nodes (or an empty sequence).

I haven't been able to find the problem.  I have a feeling that the
directory listing isn't being passed to the <p:for-each> statement.
If I comment out the <p:for-each> statement.  I am able to see the
file listing.

<?xml version="1.0" encoding="UTF-8"?>
<p:declare-step xmlns:p="http://www.w3.org/ns/xproc"
xmlns:c="http://www.w3.org/ns/xproc-step" name="p1" version="1.0">
    <p:input port="source" sequence="true"/>
    <p:output port="result" sequence="true"/>

    <p:directory-list name="list" include-filter=".*\.xml" path="1"/>


    <p:for-each name="loop-files">


        <p:output port="result">
            <p:pipe port="result" step="write2file"/>
        </p:output>

        <p:iteration-source select="/c:directory/c:file/@name"/>

        <p:variable name="file" select="/c:directory/c:file/@name"/>

        <p:load>
            <p:with-option name="href" select="$file"/>
        </p:load>

        <p:xslt name="xslt">
            <p:input port="stylesheet">
                <p:document href="../ConvertARC-To-ACE.xsl"/>
            </p:input>
            <p:input port="parameters">
                <p:empty/>
            </p:input>
        </p:xslt>


        <p:store name="write2file">
            <p:with-option name="href" select="'../SampleACE/1/', $file)"/>
            <p:input port="source"/>
        </p:store>

    </p:for-each>
</p:declare-step>

File listing when <p:for-each> statement commented out.

<c:directory name="1"
xml:base="file:/M:/Projects/NARA/Arc-to-ACE/allRecords/1/">
   <c:file name="Collection_1000.xml"/>
   <c:file name="Collection_1001.xml"/>
   <c:file name="Collection_1002.xml"/>
   <c:file name="Collection_1003.xml"/>
   <c:file name="Collection_1004.xml"/>
   <c:file name="Collection_1005.xml"/>
   <c:file name="Collection_1006.xml"/>
   <c:file name="Collection_1007.xml"/>
   <c:file name="Collection_1008.xml"/>
   ...
</c:directory>

TIA!

Betty


/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
Betty Harvey                         | Phone: 410-787-9200 FAX: 9830
Electronic Commerce Connection, Inc. |
harvey@eccnet.com                    | Washington,DC XML Users Grp
URL:  http://www.eccnet.com          | http://www.eccnet.com/xmlug/
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\\/\/
Member of XML Guild (www.xmlguild.org)


/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
Betty Harvey                         | Phone: 410-787-9200 FAX: 9830
Electronic Commerce Connection, Inc. |
harvey@eccnet.com                    | Washington,DC XML Users Grp
URL:  http://www.eccnet.com          | http://www.eccnet.com/xmlug/
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\\/\/
Member of XML Guild (www.xmlguild.org)
Received on Thursday, 12 August 2010 16:21:45 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Thursday, 12 August 2010 16:21:47 GMT