ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 6391] - Ant doesn't detect circular "depends" within an antcall.
Date Mon, 18 Feb 2002 20:58:52 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6391>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6391

Ant doesn't detect circular "depends" within an antcall.





------- Additional Comments From steve_l@iseran.com  2002-02-18 20:58 -------
You propose three fixes. #2. 'detect' by examining the graph, is the one that 
THP states is impossible without running the code. This is what you asked for 
in your original RFE.

1, 3 and 4 rely on detecting looping at run time, which is nominally tractable.

If you look at how <antcall> is implemented, it is transformed in a call of 
<ant> where buildfile=self; to implement circular dependency checking in 
<antcall> you'd probably have to do it in <ant>, which means that you need to

redesign the framework to detect (at run time) looping across multiple build 
file graphs, and distinguish callbacks and contrived execution patterns from 
real looping.

Maybe it could be done with a central (shared) list of executing targets, 
build files, properties, etc.

But it would be very hard to write, potentially hard to test as the corner 
cases that would break the process are pretty convoluted. 

But here is the key point: you shouldnt be using antcall that much anyway.

If you find your build file is too full of antcall work, then rethink how you 
are using ant, refactor the build file. split out common 'subroutine' targets 
into a separate build file.

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message