Closed Pajk closed 5 years ago
Hi @Pajk! apologies for the delay. I have only just seen this (need to fix my notifications!)
Thanks for spotting this. Could I just ask, what the .filter(pipeline => pipeline)
is for? I believe there should always be a truthy value returned from the map
function. However if that is not the case It would be great to see an example.
Ideally if you could possibly put some example YAML files in a comment that expose the issue, that would be great. I really need to get some unit tests in place (this was put together quite quickly) so that would allow me to cover this issue when I do.
Thanks for your input! Much appreciated
You're correct .filter(pipeline => pipeline)
doesn't have to be there anymore. I first tried to return null
in case the pipeline was to be excluded but then I ended up with modifying the trigger.
And without this patch it's failing in a case where you have more than one pipelines and one of them (except the last) has changeset trigger that doesn't match any changes.
Great! Your latest change makes perfect sense, I had thought about multiple pipelines but not properly tested them. Thanks for the fix :)
new version released to dockerhub with your fix :)
The plugin was failing with a multi-pipeline yaml config when one of the pipelines were excluded.
I'm testing it with Drone 1.0-rc5 and other than this it works well so far. Thanks!