Title: Help with failing style task

The <style> task is failing with a meaningless error message. Here is log from a stripped down repro buildfile

    NAnt 0.85 (Build 0.85.1932.0; rc3; 4/16/2005)
    Copyright (C) 2001-2005 Gerry Shaw
    http://nant.sourceforge.net

    Buildfile: file:///C:/Projects/TestDir/Buiild-Style/master.build
    Target framework: Microsoft .NET Framework 1.1

       [delete] Deleting file C:\DOCUME~1\TBJERS~1\LOCALS~1\Temp\tmpA99.tmp.
        [style] Loading XML file 'C:\Projects\TestDir\Buiild-Style\in.xml'.
        [style] Loading stylesheet 'C:\Projects\TestDir\Buiild-Style\failure-msg.xslt'.

    BUILD FAILED

    C:\Projects\TestDir\Buiild-Style\master.build(7,3):
    Could not perform XSLT transformation of 'C:\Projects\TestDir\Buiild-Style\in.xml' using stylesheet 'C:\Projects\TestDir\Buiild-Style\failure-msg.xslt'.

        The operation is not valid due to the current state of the object.

I can manually run the style sheet in XML Spy and it produces the expected output. So the stylesheet should not be bad.

I want to use <style> task to create an output in a TEMPORARY file. Since <style> does not have a overwrite or force attribute, I create the temp file using path::get-temp-file-name() and immediately delete it. I follow this by <style> and receive the non-helpful error message above.

Which object has an invalid state?  How do I fix this?

Stripped down files attached below.

Thanks,
Tony
<<master.build>> <<in.xml>> <<failure-msg.xslt>>


_______________________________

This message and any attachments are intended only for the use of the addressee and may contain information that is privileged and confidential.

If the reader of the message is not the intended recipient or an authorized representative of the intended recipient, you are hereby notified that any dissemination of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by e-mail and delete the message and any attachments from your system.


Attachment: master.build
Description: Binary data

Attachment: in.xml
Description: Binary data

Attachment: failure-msg.xslt
Description: Binary data

Reply via email to