Pending Pacts - pactbroker.providerBranches not working
See original GitHub issueI tried using pactbroker.providerBranches
(replacing pactbroker.providerTags
) on my provider with latest release 4.3.8
. It is not able to fetch pending and wip pacts using branches. It was able to fetch the pending and wip pacts using tags. Doing bit of investigation, it appears the problem is because this code populates providerVersionBranches
but Pact broker expects providerVersionBranch
I think (@bethesque ?). This is my suspect but I am not sure.
Pactbroker log:
2022-05-26 17:48:01.586098 I [7:puma srv tp 001] PactBroker::Api::Resources::ProviderPactsForVerification -- Fetching pacts for verification by pactdemo-provider-springboot -- {:provider_name=>"pactdemo-provider-springboot", :params=>{"consumerVersionSelectors"=>[{"mainBranch"=>true}, {"deployedOrReleased"=>true}], "includePendingStatus"=>true, "includeWipPactsSince"=>"2022-05-01", "providerVersionBranches"=>["mybranch"], "providerVersionTags"=>[]}}
Issue Analytics
- State:
- Created a year ago
- Reactions:1
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Pending pacts | Pact Docs
Enabling the "pending pacts" feature ensures the pact verification task (and therefore, the build) only fails when a breaking change causes ...
Read more >Wrong pending status resolving while WIP pacts feature ...
A pact's content is pending for all branches of a provider until the first successful verification has been published. From then on, it...
Read more >Pact Broker - What is the difference between the pact jvm ...
providerBranch is used for setting the current branch of the provider repository were running the verification? To prevent that a verification ...
Read more >Pending Pacts — What Are They Exactly? - codeburst
In order to make it work you need two compatible ingredients — a pact library and the Pact Broker that support the pending...
Read more >And what is the value we should pass to those variables | Pact ...
Beth (pactflow.io/Pact Broker/pact-ruby). 10/06/2022, 3:56 PM. PR branch or Master branch. Which ever branch is running the build.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
sure, I will give it a shot.
Hi,
I think you are correct
https://github.com/pact-foundation/pact-ruby/blob/f0e37a4794e72d0a469298ff592d69f1304c9022/lib/pact/pact_broker/fetch_pact_uris_for_verification.rb#L82-L83
providerVersionBranches
refs only exist in pact-jvmhttps://github.com/search?q=providerVersionBranches&type=code
providerVersionBranch
refs exist in several locataions (docs and source)https://github.com/search?q=providerVersionBranch&type=code
Also looking at the code, it’s expecting a single value string not an array
Would happily accept a pull request if you have time?