RE: c namespace in output

No, no inline documents. The document comes in on the input port and out on output. I can strip the pipeline down to a simple one-step exec and unwrap and it still exhibits the problem for me:
 
<p:pipeline version="1.0" xmlns:p="http://www.w3.org/ns/xproc" xmlns:c=http://www.w3.org/ns/xproc-step>
<p:exec name="exec" command="c:/library/_bin/Applications/format.exe"
source-is-xml="true"
result-is-xml="true"
wrap-result-lines="false">
<p:with-option name="args" select="'-fs -re=c:/library/XMLGen/re/xform_daisy202.xml'"/>
</p:exec>
<p:unwrap match="c:result"/>
</p:pipeline>

 
I took at look at exclude-inline-prefixes, but didn't seem to apply to this scenario (at least as far as I can tell). If I remove the unwrap step, the c prefix is only declared on the wrapper c:result element, so it's only getting added to the document root as part of the unwrap.
 
Appreciate any insight you can give me on what I might be doing wrong here, though.
 
Matt
 


From: vojtech.toman@emc.com
To: xproc-dev@w3.org
Date: Tue, 7 Dec 2010 05:33:26 -0500
Subject: RE: c namespace in output






Hi,
 
Typically, the “unwanted” namespace declarations appear in the result because they are in-scope in the p:inline bindings that you specify in the pipeline. For example, if you do something like this:
 
<p:pipeline xmlns:foo=”bar”>
  …
  <p:identity>
    <p:input port=”source”>
      <p:inline><doc></p:inline>
    </p:input>
  </p:identity>
  …
</p:pipeline>
 
then the result of p:identity will be <doc xmlns:foo=”bar”/>
 
To prevent certain prefixes from appearing in inline bindings, you can use the exclude-inline-prefixes attribute on p:inline or on the container p:pipeline/p:declare-step. This will filter out all prefixes specified in exclude-inline-prefixes, provided that they are not used in the document. Thus:
 
<p:pipeline xmlns:foo=”bar”>
  …
  <p:identity>
    <p:input port=”source”>
      <p:inline exclude-inline-prefixes=”bar”><doc></p:inline>
    </p:input>
  </p:identity>
  …
</p:pipeline>
 
produces: <doc/>
 
(You can also exclude all unused prefixes by using exclude-inline-prefixes=”#all”.)
 
But without seeing your actual pipeline I cannot tell if exclude-inline-prefixes would help in your case, or if it is a bug in Calabash.
 
Regards,
Vojtech
 

 
--
Vojtech Toman
Consultant Software Engineer
EMC | Information Intelligence Group
vojtech.toman@emc.com
http://developer.emc.com/xmltech
 



From: xproc-dev-request@w3.org [mailto:xproc-dev-request@w3.org] On Behalf Of Matt Garrish
Sent: Monday, December 06, 2010 7:32 PM
To: xproc-dev@w3.org
Subject: c namespace in output
 
Hi everyone,
 
When I do a p:exec followed by a p:unwrap I noticed I get a namespace declaration for the c namespace on the root xml element, which obviously has no use in the output document. For an xhtml document, for example, I get:
 
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:c="http://www.w3.org/ns/xproc-step">
 
After much pondering I realized I can remove the namespace declaration by adding:
 
<p:namespace-rename from="http://www.w3.org/ns/xproc-step" to=""/>
 
at the end of the pipeline, but just wondering if this is the “accepted” way to do this, or if I’ve just sinned against all things pipeline? :)
 
(Using Calabash 0.9.28 on WinXP.)
 
Thanks,
 
Matt 		 	   		  

Received on Tuesday, 7 December 2010 15:24:45 UTC