So we've been playing around with the CI aspect of...
# pact-broker
w
So we've been playing around with the CI aspect of Pact and saw after a branch gets merged to main, we noticed that the consumer pact for the merged branch still exists as one of the contracts for the integration. Is there a way to have those be deleted once the PR is closed or do we have to manually prune (and if so how)? We seem to have a lot of them because of things like renovatebot for github actions so it quickly is cluttering up Pactflow and makes it hard to see the contract (on main) that we care about. Or is there another feature/implementation route we missed in configuring the CI? a. i.e. we see a main <--> main contract but also still the original BRANCH/123 <---> main contract
👍 1
b
Really good question. I’ve had branch clean up on my mental todo list for a while, but I don’t think we’ve got it in our backlog. Can you raise a feature request in pact.canny.io?
There’s a batch “clean up” feature, but it is based on version age, so it can’t tell if a git branch has been deleted or not. https://docs.pact.io/pact_broker/administration/maintenance
w
👍🏼 1
b
@Wayne Ng it’s not the most convenient way to do it, but you can always clear up the pacts via the API https://docs.pact.io/pact_broker/administration/deleting_resources#deleting-multiple-pacts