-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pending pacts and can-i-deploy #105
Comments
It's a tricky situation. But, your consumer has broken the rules by ignoring this check. We could add more configuration/options, but it feels like it just makes the shooting of your feet more likely. This implies the tools have been circumvented, so you could collectively circumvent them again to resolve the situation. This would be somewhat analogous to allowing you to regular |
Yeah I agree. We have some additional tests after the deployment we need and it is expected that every pacticipant can use one environment (test) and deploy and test ... let's say wildly ;). We include this environment in our can-i-deploy checks for faster feedback. I think this is our main issue at the moment. We do: We do it like that, because as said we need the deploy step on the test environment for the additional tests. This is why we did not put a can-i-deploy (test) infront of the deployment. Then it felt wrong not to include the record-deployment step afterwards. We were not sure where to include the can-i-deploy then. So we said ok at the end so that the teams still have the feedback from their tests etc. but also fast feedback from pact. Maybe we can exclude test in can-i-deploy at the end, because as said we need to able to deploy there at any time and then maybe the can-i-deploy check makes no sense for this environment. Or we can check if the usage of pending interactions can help us as well. Nevertheless, I still want to ask regarding providing the information if a pact is pending or not also during the can-i-deploy step. Isn't that also a valid information, without changing anything regarding the can-i-deploy checks, but it provides us the info, ok somebody did something illegal or provides more flexibility for the different kinds of pipeline definitions? Thx for the fast feedback btw. |
I suppose a |
We actually ran into something similar where because we have pending pacts and WIP turned on, junit essentially ignores the failures. The problem is that unless the dev is intimately familiar with pact, they assume that everything is ok and could potentially merge a PR that is actually not going to let them deploy. Since the failure is essentially “hidden” by junit, a PR pipeline could still pass and be merged. Especially true if something like auto merge is turned on |
@mefellows But due to the switched roles in async this is not the case. So can-i-deploy would force us to deploy System A first, which would result in message lost or if the SQS queue is already created in a queue, in which the message would pile up. @mefellows are there any news regarding --allow-pending? |
Hi,
I was wondering. We have the situation that a consumer created a new pact with a new state, which results in a pending pact. This works fine in our pipeline during the junit tests. We can see in the logs that the broker provided the pact, but the junit test ignores it because it is pending. So far so good.
The issue we face now is that the consumer deployed this changes already. This is breaking our pipeline because the can-i-deploy feature then tells us that we are breaking this pact.
I mean ok the consumer should not deploy. I get that part, but it also is a bit strange that our tests are fine with the pending pact and ignores it, but the can-i-deploy feature then complains that we are violating the pact.
Should not the can-i-deploy feature ignore pending pacts as well? We checked if we could ignore pending pacts in our pipeline manually. We are using https://docs.pact.io/pact_broker/client_cli/readme#can-i-deploy. But the issue is the json response does not include the pending pact information.
Do I have the wrong expectations here? What is your opinion?
Br,
Chris
The text was updated successfully, but these errors were encountered: