We have some tasks that run at the end of a rather long build. These tasks might fail if some conditions are not met, e.g. an expected file is missing somewhere, etc. It is problematic to wait for the long build to complete and only learn at the very end that a file is missing (or something else).
It would be very helpful if every task can implement a callback that is invoked when the task graph is ready, but only if the task is actually part of the task graph. The task could then check the pre-conditions and fail the build if they are not met?
Any thoughts on this? Already achievable today?