Mike,

This is a known issue
(http://sourceforge.net/tracker/index.php?func=detail&aid=788650&group_id=31
650&atid=402868), which is probably very easy to fix.  But I was actually
waiting for a good proposal for the xml structure.

Taken from the existing bug report :

"Currently the layout of the xml logger output is something like
this :

<buildresults project="...">
   <message level="Info">....</message>
   <target name="...">
      <task name="...">
         ....
      </task>
   </target>
</buildresults>

we could rename the "buildresults" node to
"build", and add a
result node under that node with a status attribute (with
possible values "failure" or "success") and
output the details
of the build failure as content of that node.

eg.

<build project="...">
   <result status="Failure">
      Unable to ....
   </result>
</build>"

Can you propose something, then I'll implement it. Does that sound ok ? :-)

Gert

----- Original Message ----- 
From: "Mike Roberts" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, February 25, 2004 10:10 PM
Subject: [Nant-users] Bug when using XmlLogger and build exceptions


> Hi there,
>
> We've been seeing a problem for a while when using CruiseControl.NET
> where if a NAnt build fails due to an exception then the reason is not
> outputted. We use the xmllogger when driving NAnt from CCNet so that we
> can style the output later.
>
> I always thought that it would be on standard error, and we just weren't
> capturing it properly, but it appears that there's actually a bug, which
> I can reproduce. Attached are some details - are there any plans to fix
> this?
>
> Cheers,
>
> Mike
>
> --
>
> C:\tools\eclipse\workspace\ccnet>type temp.build
> <project name="example" default="all">
>
>   <target name="makeexception">
>                 <script language="C#">
>                         <code><![CDATA[
>                                 public static void ScriptMain(Project
> project)
>                                 {
>                                         throw new Exception("Making
> target throw exception");
>                                 }
>                         ]]></code>
>                 </script>
>   </target>
>
> </project>
> C:\tools\eclipse\workspace\ccnet>tools\nant\nant.exe
> -buildfile:temp.build makeexception
> NAnt 0.84 (Build 0.84.1435.0; net-1.0.win32; rc 1; 06/12/2003)
> Copyright (C) 2001-2003 Gerry Shaw
> http://nant.sourceforge.net
>
> Buildfile: file:///C:/tools/eclipse/workspace/ccnet/temp.build
> Target(s) specified: makeexception
>
> makeexception:
>
>
> BUILD FAILED
>
> C:\tools\eclipse\workspace\ccnet\temp.build(4,4):
> Script exception.
>  Making target throw exception
>
> Total time: 1.6 seconds.
>
>
> C:\tools\eclipse\workspace\ccnet>tools\nant\nant.exe
> -logger:NAnt.Core.XmlLogger -buildfile:temp.build makeexception
> NAnt 0.84 (Build 0.84.1435.0; net-1.0.win32; rc 1; 06/12/2003)
> Copyright (C) 2001-2003 Gerry Shaw
> http://nant.sourceforge.net
>
> <buildresults project="example">
>   <message level="Info"><![CDATA[Buildfile:
> file:///C:/tools/eclipse/workspace/ccnet/temp.build]]></message>
>   <message level="Info"><![CDATA[Target(s) specified:
> makeexception]]></message>
>   <target name="makeexception">
>     <task name="script" />
>   </target>
> </buildresults>
> C:\tools\eclipse\workspace\ccnet>
>
>
>
> -------------------------------------------------------
> SF.Net is sponsored by: Speed Start Your Linux Apps Now.
> Build and deploy apps & Web services for Linux with
> a free DVD software kit from IBM. Click Now!
> http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
> _______________________________________________
> Nant-users mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/nant-users
>
>



-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
_______________________________________________
Nant-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/nant-users

Reply via email to