You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bu...@apache.org on 2021/10/22 12:14:53 UTC

[Bug 65647] New: Attribute "quiet" of task "LoadResource" not working as described

https://bz.apache.org/bugzilla/show_bug.cgi?id=65647

            Bug ID: 65647
           Summary: Attribute "quiet" of task "LoadResource" not working
                    as described
           Product: Ant
           Version: 1.10.12
          Hardware: PC
            Status: NEW
          Severity: minor
          Priority: P2
         Component: Core tasks
          Assignee: notifications@ant.apache.org
          Reporter: michael.luber@siemens.com
  Target Milestone: ---

https://ant.apache.org/manual/Tasks/loadresource.html
says about the attribute "quiet":

Do not display a diagnostic message (unless Ant has been invoked with the
-verbose or -debug switches)

Using the task "LoadFile" which is derived from "LoadResource", I
found that this does not work. I tried this ANT-script:

<project name="MyProject" default="all">
  <target name="all" >
      <loadfile property="filecontent" srcFile="noSuchFile" quiet="true"/>
  </target>
</project>

which produces:

all:
 [loadfile] D:\git\brake\s7p.build\ant\noSuchFile doesn't exist


The reason for that is that in
apache-ant-1.10.12\src\main\org\apache\tools\ant\taskdefs\LoadResource.java, in
method execute(), if the file does not exist, we issue

log(message, quiet ? Project.MSG_WARN : Project.MSG_ERR);

which should be

log(message, quiet ? Project.MSG_VERBOSE: Project.MSG_ERR);

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 65647] Attribute "quiet" of task "LoadResource" not working as described

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=65647

Stefan Bodewig <bo...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 OS|                            |All
         Resolution|---                         |FIXED
   Target Milestone|---                         |1.10.13
             Status|NEW                         |RESOLVED

--- Comment #1 from Stefan Bodewig <bo...@apache.org> ---
yes, you are correct, thank you

-- 
You are receiving this mail because:
You are the assignee for the bug.