Base URI is lost through p:xslt #94

Closed
josteinaj opened this Issue Mar 22, 2013 · 1 comment

Comments

Projects
None yet
2 participants
@josteinaj
Contributor

josteinaj commented Mar 22, 2013

So this pipeline:

<?xml version="1.0" encoding="UTF-8"?>
<p:declare-step xmlns:p="http://www.w3.org/ns/xproc" version="1.0">
    <p:input port="source">
        <p:inline>
            <doc xml:base="file:/tmp/"/>
       </p:inline>
    </p:input>
    <p:output port="result"/>
    <p:delete match="/*/@xml:base"/>
    <p:add-attribute match="/*" attribute-name="base-before">
        <p:with-option name="attribute-value" select="base-uri(/*)"/>
    </p:add-attribute>
    <p:xslt>
        <p:input port="parameters">
            <p:empty/>
        </p:input>
        <p:input port="stylesheet">
            <p:inline>
                <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="2.0">
                    <xsl:template match="/">
                        <xsl:copy-of select="/"/>
                    </xsl:template>
                </xsl:stylesheet>
            </p:inline>
        </p:input>
    </p:xslt>
    <p:add-attribute match="/*" attribute-name="base-after">
        <p:with-option name="attribute-value" select="base-uri(/*)"/>
    </p:add-attribute>
</p:declare-step>

Gives me this on the output port:

<doc base-after="file:/home/jostein/preserve-base-test.xpl" base-before="file:/tmp/"/>

I would expect to get this:

<doc base-after="file:/tmp/" base-before="file:/tmp/"/>

See also the discussion on the xproc-dev list: http://lists.w3.org/Archives/Public/xproc-dev/2013Mar/0013.html

(Tested on version 1.0.8.94 of calabash)

@ndw

This comment has been minimized.

Show comment
Hide comment
@ndw

ndw Mar 22, 2013

Owner

There does seem to be something odd here. I'm investigating.

Owner

ndw commented Mar 22, 2013

There does seem to be something odd here. I'm investigating.

@ndw ndw closed this Mar 26, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment