Is it possible to instruct BuildBot that a step is an "allowed failure", that is to NOT mark build as failed even if this particular step fails?
I have found a warnOnFailure
parameter for a build step (would prefer "ignoreOnFailure"), but it doesn't seem to be working in my BuildBot (2.1.0, twisted 18.9.0). Even if I set it to True, the overall build is still marked as failed.
I have had success with ShellCommand's decodeRC parameter, but then I lose the indication that the step failed, so it's a sub-optimal solution.
This is how I generate the steps:
self.build.addStepsAfterCurrentStep([
steps.ShellCommand(name=stage + ' ' + ('allowed failure' if allowed_failure(stage) else ''),
logEnviron=False,
warnOnFailure=allowed_failure(stage), # This one would be desired but doesn't seem to work
command=['tox', '-e', stage],
env={ 'PYTHONPATH': '.' },
decodeRC={0:SUCCESS,1:SUCCESS}) # This one works, but marks the step as SUCCESSFUL, which I don't want
for stage in self.extract_stages(self.observer.getStdout())
])
Please note the inline comments.
Is there a more obvious way of setting this up?