diff --git a/script/github-issues/add-branch-support-for-provider-versions/issue-text.txt b/script/github-issues/add-branch-support-for-provider-versions/issue-text.txt new file mode 100644 index 000000000..34d547dbd --- /dev/null +++ b/script/github-issues/add-branch-support-for-provider-versions/issue-text.txt @@ -0,0 +1,9 @@ +Add support for publishing verification results with a branch using the pact-ruby-standalone + +The Pact Broker now supports branches as first class entities. You can read more about this here: https://github.com/pact-foundation/docs.pact.io/blob/feat/deployments-and-releases/website/blog/2021-07-04-why-we-are-getting-rid-of-tags.md + +To allow users to use this feature: + +* Upgrade the pact-ruby-standalone to at least version `1.88.70` +* Add an appropriately prefixed "branch" property to the user facing interface (make it match the existing provider name, tag, and version properties) +* Pass the branch through to the pact provider verifier CLI using the parameter `--provider-version-branch` diff --git a/script/github-issues/add-branch-support-for-provider-versions/issues.txt b/script/github-issues/add-branch-support-for-provider-versions/issues.txt new file mode 100644 index 000000000..68e7a21a8 --- /dev/null +++ b/script/github-issues/add-branch-support-for-provider-versions/issues.txt @@ -0,0 +1,6 @@ +https://github.com/pact-foundation/pact-js/issues/750 +https://github.com/pact-foundation/pact-net/issues/327 +https://github.com/pact-foundation/pact-python/issues/267 +https://github.com/pact-foundation/pact-php/issues/223 +https://github.com/pact-foundation/pact-go/issues/180 +https://github.com/DiUS/pact-consumer-swift/issues/127 diff --git a/script/github-issues/add-branch-support-for-provider-versions/raise-issue-in-client-repos.sh b/script/github-issues/add-branch-support-for-provider-versions/raise-issue-in-client-repos.sh new file mode 100755 index 000000000..861a7c19d --- /dev/null +++ b/script/github-issues/add-branch-support-for-provider-versions/raise-issue-in-client-repos.sh @@ -0,0 +1,10 @@ +#!/bin/sh + +repos="pact-js pact-net pact-python pact-php pact-go pact-consumer-swift" + +issue_text_file=$(realpath $(dirname "$0")/issue-text.txt) + +for repo in $repos; do + cd "../${repo}" + hub issue create --file "${issue_text_file}" --labels "help wanted,enhancement" +done diff --git a/script/github-issues/add-branch-support/issue-text.txt b/script/github-issues/add-branch-support/issue-text.txt new file mode 100644 index 000000000..db990cd85 --- /dev/null +++ b/script/github-issues/add-branch-support/issue-text.txt @@ -0,0 +1,7 @@ +Add branch support + +The Pact Broker now supports branches as first class entities. You can read more about this here: https://github.com/pact-foundation/docs.pact.io/blob/feat/deployments-and-releases/website/blog/2021-07-04-why-we-are-getting-rid-of-tags.md + +Please add support for branches in the following way (depending on how you publish pacts and verifications): + +* If this \ No newline at end of file diff --git a/script/github-issues/add-branch-support/issues.txt b/script/github-issues/add-branch-support/issues.txt new file mode 100644 index 000000000..e69de29bb diff --git a/script/github-issues/add-branch-support/raise-issue-in-client-repos.sh b/script/github-issues/add-branch-support/raise-issue-in-client-repos.sh new file mode 100755 index 000000000..491b9427a --- /dev/null +++ b/script/github-issues/add-branch-support/raise-issue-in-client-repos.sh @@ -0,0 +1,10 @@ +#!/bin/sh + +repos="pact-js pact-jvm pact-net pact-python scala-pact pact-php pact-go pact pact-reference pact4s" + +issue_text_file=$(realpath $(dirname "$0")/issue-text.txt) + +for repo in $repos; do + cd "../${repo}" + hub issue create --file "${issue_text_file}" --labels "help wanted,good first issue,enhancement" +done diff --git a/script/github-issues/branch-consumer-version-selector/issue-text.txt b/script/github-issues/branch-consumer-version-selector/issue-text.txt new file mode 100644 index 000000000..238017030 --- /dev/null +++ b/script/github-issues/branch-consumer-version-selector/issue-text.txt @@ -0,0 +1,47 @@ +Add support for branches in consumer version selectors used + +The Pact Broker now supports branches as first class entities. You can read more about this here: https://docs.pact.io/pact_broker/branches + +## Description + +Please add support for specifying branch related properties in the consumer version selectors that are sent to the Pact Broker when requesting pacts to verify. Please do not do any verification of the consumer version selectors on the client side - the validation rules are subject to change. Just ensure that any error response is displayed to the user. + +* Allow a String `branch` property to be set for the consumer version selector. +* Allow a Boolean `mainBranch` property to be set for the consumer version selector. +* Expose and document the `branch` and `mainBranch` properties in the user facing API. + +## Verifying the changes + +* Publish tests pacts to the test broker + +``` +export PACT_BROKER_BASE_URL="https://test.pact.dius.com.au" +export PACT_BROKER_USERNAME="dXfltyFMgNOFZAxr8io9wJ37iUpY42M" +export PACT_BROKER_PASSWORD="O5AIZWxelWbLvqMd8PkAVycBJh2Psyg1" + +docker run --rm \ + -e PACT_BROKER_BASE_URL \ + -e PACT_BROKER_USERNAME \ + -e PACT_BROKER_PASSWORD \ + pactfoundation/pact-cli:0.50.0.14 \ + publish \ + /pact/example/pacts \ + --consumer-app-version fake-git-sha-for-demo-$(date +%s) \ + --branch main + +docker run --rm \ + -e PACT_BROKER_BASE_URL \ + -e PACT_BROKER_USERNAME \ + -e PACT_BROKER_PASSWORD \ + pactfoundation/pact-cli:0.50.0.14 \ + publish \ + /pact/example/pacts \ + --consumer-app-version fake-git-sha-for-demo-$(date +%s) \ + --branch feat/x +``` + +* Using your pact client library, verify `{ "mainBranch": true }` + * You should receive the main pact +* Using your pact client library, verify `{ "branch": "feat/x" }` + * You should receive the feat/x pact + diff --git a/script/github-issues/branch-consumer-version-selector/issues.txt b/script/github-issues/branch-consumer-version-selector/issues.txt new file mode 100644 index 000000000..e69de29bb diff --git a/script/github-issues/branch-consumer-version-selector/raise-issue-in-client-repos.sh b/script/github-issues/branch-consumer-version-selector/raise-issue-in-client-repos.sh new file mode 100755 index 000000000..f9407e869 --- /dev/null +++ b/script/github-issues/branch-consumer-version-selector/raise-issue-in-client-repos.sh @@ -0,0 +1,10 @@ +#!/bin/sh + +repos="pact-js pact-jvm pact-net pact-python scala-pact pact-php pact-go pact-reference pact4s pact-consumer-swift" + +issue_text_file=$(realpath $(dirname "$0")/issue-text.txt) + +for repo in $repos; do + cd "../${repo}" + hub issue create --file "${issue_text_file}" --labels "help wanted,good first issue,enhancement" +done diff --git a/script/issues/consumer-version-selectors-docs/issue-text.txt b/script/github-issues/consumer-version-selectors-docs/issue-text.txt similarity index 100% rename from script/issues/consumer-version-selectors-docs/issue-text.txt rename to script/github-issues/consumer-version-selectors-docs/issue-text.txt diff --git a/script/issues/consumer-version-selectors-docs/issues.txt b/script/github-issues/consumer-version-selectors-docs/issues.txt similarity index 100% rename from script/issues/consumer-version-selectors-docs/issues.txt rename to script/github-issues/consumer-version-selectors-docs/issues.txt diff --git a/script/issues/consumer-version-selectors-docs/raise-issue-in-client-repos.sh b/script/github-issues/consumer-version-selectors-docs/raise-issue-in-client-repos.sh similarity index 100% rename from script/issues/consumer-version-selectors-docs/raise-issue-in-client-repos.sh rename to script/github-issues/consumer-version-selectors-docs/raise-issue-in-client-repos.sh diff --git a/script/github-issues/deployed-and-released-selectors-docs/issue-text.txt b/script/github-issues/deployed-and-released-selectors-docs/issue-text.txt new file mode 100644 index 000000000..b31bb6a18 --- /dev/null +++ b/script/github-issues/deployed-and-released-selectors-docs/issue-text.txt @@ -0,0 +1,26 @@ +Add support for consumer version selectors for deployed and released versions + +Please add support for the following keys to be used in the consumer version selectors when fetching pacts for verification: + +``` +{ "deployedOrReleased": true } + +{ "deployed": true } + +{ "released": true } + +{ "environment": "" } + +{ "deployed": true } + +{ "released": true } + +``` + +These keys can be used in various combinations ( eg. `{ "environment": "prod", released: true, consumer: "Foo" }` ). Please allow any combination of keys, and do not validate them locally, as the validation rules can change over time as support is added for new selectors - just ensure that any errors returned from the API are displayed clearly to the user. + +See https://github.com/pact-foundation/pact_broker/blob/master/lib/pact_broker/doc/views/provider-pacts-for-verification.markdown for the usage docs of each selector. + +As more selectors will be added over time, it's my preference that the consumer version selectors are not strongly typed, and are just passed through straight from the configuration object to the API, so that we don't have to make code changes to the Pact clients each time we add new selectors. (eg. there will be new selectors coming for branch support very soon). I understand that this is not compatible with the idioms of every Pact client language however, so do whatever you need to do to make the new selectors work elegantly within your language. + +Please update https://docs.pact.io/pact_broker/advanced_topics/consumer_version_selectors/ for your language once the selectors have been released. diff --git a/script/github-issues/deployed-and-released-selectors-docs/issues.txt b/script/github-issues/deployed-and-released-selectors-docs/issues.txt new file mode 100644 index 000000000..a91d8bb03 --- /dev/null +++ b/script/github-issues/deployed-and-released-selectors-docs/issues.txt @@ -0,0 +1,9 @@ +https://github.com/pact-foundation/pact-js/issues/715 +https://github.com/pact-foundation/pact-jvm/issues/1407 +https://github.com/pact-foundation/pact-net/issues/311 +https://github.com/pact-foundation/pact-python/issues/246 +https://github.com/ITV/scala-pact/issues/224 +https://github.com/pact-foundation/pact-php/issues/206 +https://github.com/pact-foundation/pact-go/issues/172 +https://github.com/pact-foundation/pact-ruby/issues/243 +https://github.com/pact-foundation/pact-reference/issues/125 diff --git a/script/github-issues/deployed-and-released-selectors-docs/raise-issue-in-client-repos.sh b/script/github-issues/deployed-and-released-selectors-docs/raise-issue-in-client-repos.sh new file mode 100755 index 000000000..9db2fb41f --- /dev/null +++ b/script/github-issues/deployed-and-released-selectors-docs/raise-issue-in-client-repos.sh @@ -0,0 +1,10 @@ +#!/bin/sh + +repos="pact-js pact-jvm pact-net pact-python scala-pact pact-php pact-go pact pact-reference" + +issue_text_file=$(realpath $(dirname "$0")/issue-text.txt) + +for repo in $repos; do + cd "../${repo}" + hub issue create --file "${issue_text_file}" --labels "help wanted,good first issue,enhancement" +done diff --git a/script/github-issues/include-pending-by-default/issue-text.txt b/script/github-issues/include-pending-by-default/issue-text.txt new file mode 100644 index 000000000..ff8a7af10 --- /dev/null +++ b/script/github-issues/include-pending-by-default/issue-text.txt @@ -0,0 +1,5 @@ +Set "enable pending" to true by default + +The [pending](https://docs.pact.io/pending) feature has been used for long enough now to show that it works, and that there is little reason to ever have it turned off any more. The Pact Broker now defaults to `true` if the `includePendingStatus` field is not set, however, this will not take effect if the client side has it set to false by default. Please set `enablePending` to true by default now, to ensure it is turned on for all older and future versions of the Pact Broker. + +Consider printing a warning message if the user does set it to false explicitly, along the lines of "We recommend setting enablePending to true. For more information, please see https://docs.pact.io/pending" diff --git a/script/github-issues/include-pending-by-default/issues.txt b/script/github-issues/include-pending-by-default/issues.txt new file mode 100644 index 000000000..e51547383 --- /dev/null +++ b/script/github-issues/include-pending-by-default/issues.txt @@ -0,0 +1,10 @@ +https://github.com/pact-foundation/pact-js/issues/740 +https://github.com/pact-foundation/pact-jvm/issues/1440 +https://github.com/pact-foundation/pact-net/issues/322 +https://github.com/pact-foundation/pact-python/issues/264 +https://github.com/ITV/scala-pact/issues/228 +https://github.com/pact-foundation/pact-php/issues/221 +https://github.com/pact-foundation/pact-go/issues/178 +https://github.com/pact-foundation/pact-ruby/issues/246 +https://github.com/pact-foundation/pact-reference/issues/143 +https://github.com/jbwheatley/pact4s/issues/69 \ No newline at end of file diff --git a/script/github-issues/include-pending-by-default/raise-issue-in-client-repos.sh b/script/github-issues/include-pending-by-default/raise-issue-in-client-repos.sh new file mode 100755 index 000000000..491b9427a --- /dev/null +++ b/script/github-issues/include-pending-by-default/raise-issue-in-client-repos.sh @@ -0,0 +1,10 @@ +#!/bin/sh + +repos="pact-js pact-jvm pact-net pact-python scala-pact pact-php pact-go pact pact-reference pact4s" + +issue_text_file=$(realpath $(dirname "$0")/issue-text.txt) + +for repo in $repos; do + cd "../${repo}" + hub issue create --file "${issue_text_file}" --labels "help wanted,good first issue,enhancement" +done