Should I submit this Bugzilla?
John-Mason Shackelford Software Developer NCS Pearson - Measurement Services 2510 North Dodge St. Iowa City, IA 52245 319-354-9200x6214 [EMAIL PROTECTED] > -----Original Message----- > From: Shackelford, John-Mason [mailto:[EMAIL PROTECTED]] > Sent: Monday, July 29, 2002 9:42 AM > To: 'Ant Users List' > Subject: RE: strange behavior with antcall > > > Greetings, > > I have come to the conclusion that the problem I was having > with antcall is > either a bug in ant or a problem with the docs. The > documentation for both > antcall and ant states: > > You can also set properties in the new project from the old > project by using > nested param tags. These properties are always passed > regardless of the > setting of inheritAll. This allows you to parameterize your > subprojects. > > I have written a few short build files to demonstrate that this is not > always the case. > > Run the following test: > > $ ant -buildfile zoo.xml feed.one feed.two feed.three > > This will display the properties listed in the property file > as expected. > > Now try: > > $ ant -buildfile zoo.xml feed.one feed.two feed.three feed.two > > Instead of repeating the line for animal two: > > [echo] John-Mason is going to feed the tiger his favorite: people > > you will see a fourth animal mentioned: > > [echo] John-Mason is going to feed the monkey (default) his favorite: > bananas (default) > > This, I contend, is the bug. Instead of taking the value from > the params > passed in as previously, on the second antcall from a single > target the > properties are drawn from the caller's environment. > > By using inheritAll=false this behavior is illiminated. You > will see this by > trying: > > $ ant -buildfile zoo.xml feed.one feed.two feed.three feed.three > > The third animal line is repeated as expected. While this is a viable > workaround, according to the docs when nested param tags are used, the > properties are always passed in regardless of the setting of > inheritAll. > > I have also enclosed zoo2.xml and zoo-callable.xml. These > domonstrate that > the same bug exists when using ant instead of antcall. Use > the same args: > > $ ant -buildfile zoo2.xml feed.one feed.two feed.three feed.two > $ ant -buildfile zoo2.xml feed.one feed.two feed.three feed.three > > > If I have missed something here, please send your gentle rebuke. > > John-Mason Shackelford > > Software Developer > NCS Pearson - Measurement Services > 2510 North Dodge St. > Iowa City, IA 52245 > 319-354-9200x6214 > [EMAIL PROTECTED] > > > -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
