Skip to content
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

[PR #1221/20f2afd7 backport][stable-3] aws_codebuild - Add resource_tags parameter and deprecate tags #1224

Conversation

patchback[bot]
Copy link

@patchback patchback bot commented Jun 7, 2022

This is a backport of PR #1221 as merged into main (20f2afd).

SUMMARY

aws_codebuild currently uses the boto3 style 'list of dictionaries' format rather than the usual dictionary format.

  • Add a resource_tags parameter that accepts the usual dictionary format
  • Add the purge_tags parameter
  • deprecate the tags parameter in preparation for switching it to the usual dict format
  • expand integration tests for tags and description
  • make source and artifacts optional unless creating a new project
  • fix bug with inconsistent "changed" state due to tag order not being guaranteed
ISSUE TYPE
  • Bugfix Pull Request
  • Feature Pull Request
COMPONENT NAME

aws_codebuild

ADDITIONAL INFORMATION

The (boto3) tags format in the return value when describing a project makes no guarantees about the order it'll return the key/value pairs. As such, when multiple tags were set the naïve original == new comparison would sporadically return "changed" when no change had occurred.

aws_codebuild - Add resource_tags parameter and deprecate tags

SUMMARY
aws_codebuild currently uses the boto3 style 'list of dictionaries' format rather than the usual dictionary format.

Add a resource_tags parameter that accepts the usual dictionary format
Add the purge_tags parameter
deprecate the tags parameter in preparation for switching it to the usual dict format
expand integration tests for tags and description
make source and artifacts optional unless creating a new project
fix bug with inconsistent "changed" state due to tag order not being guaranteed

ISSUE TYPE

Bugfix Pull Request
Feature Pull Request

COMPONENT NAME
aws_codebuild
ADDITIONAL INFORMATION
The (boto3) tags format in the return value when describing a project makes no guarantees about the order it'll return the key/value pairs.  As such, when multiple tags were set the naïve original == new comparison would sporadically return "changed" when no change had occurred.

Reviewed-by: Joseph Torcasso <None>
Reviewed-by: Mark Chappell <None>
(cherry picked from commit 20f2afd)
@ansibullbot
Copy link

@ansibullbot ansibullbot added bug This issue/PR relates to a bug community_review integration tests/integration module module needs_triage new_contributor Help guide this first time contributor plugins plugin (any type) tests tests labels Jun 7, 2022
@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.

ansible-galaxy-importer FAILURE in 4m 08s (non-voting)
✔️ build-ansible-collection SUCCESS in 6m 07s
✔️ ansible-test-sanity-docker-devel SUCCESS in 11m 34s (non-voting)
✔️ ansible-test-sanity-docker-milestone SUCCESS in 10m 08s
✔️ ansible-test-sanity-docker-stable-2.9 SUCCESS in 13m 51s
✔️ ansible-test-sanity-docker-stable-2.11 SUCCESS in 9m 57s
✔️ ansible-test-sanity-docker-stable-2.12 SUCCESS in 10m 13s
✔️ ansible-test-units-community-aws-python38 SUCCESS in 5m 50s
✔️ ansible-test-units-community-aws-python39 SUCCESS in 6m 34s
✔️ ansible-test-splitter SUCCESS in 2m 24s
✔️ integration-community.aws-1 SUCCESS in 7m 57s
⚠️ integration-community.aws-2 SKIPPED
⚠️ integration-community.aws-3 SKIPPED
⚠️ integration-community.aws-4 SKIPPED
⚠️ integration-community.aws-5 SKIPPED
⚠️ integration-community.aws-6 SKIPPED
⚠️ integration-community.aws-7 SKIPPED
⚠️ integration-community.aws-8 SKIPPED
⚠️ integration-community.aws-9 SKIPPED
⚠️ integration-community.aws-10 SKIPPED
⚠️ integration-community.aws-11 SKIPPED
⚠️ integration-community.aws-12 SKIPPED
⚠️ integration-community.aws-13 SKIPPED

Copy link
Contributor

@alinabuzachis alinabuzachis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not fully sure we'd like to merge this to stable-3.

@alinabuzachis alinabuzachis self-requested a review June 7, 2022 12:09
@markuman
Copy link
Member

markuman commented Jun 7, 2022

Not fully sure we'd like to merge this to stable-3.

it's just introduce a deprecation. No breaking change. I'm fine with that. Users should be informed as early as possible.

@tremble tremble added the mergeit Merge the PR (SoftwareFactory) label Jun 7, 2022
different formats.
returned: when configured
type: dict
version_added: 4.0.0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@markuman @tremble But what about these params here? version_added: is 4.0.0.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ups

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll update that and backport if/when this is merged.

@markuman markuman added mergeit Merge the PR (SoftwareFactory) and removed mergeit Merge the PR (SoftwareFactory) labels Jun 7, 2022
@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded (gate pipeline).

ansible-galaxy-importer FAILURE in 4m 18s (non-voting)
✔️ build-ansible-collection SUCCESS in 5m 30s
✔️ ansible-test-sanity-docker-devel SUCCESS in 11m 07s (non-voting)
✔️ ansible-test-sanity-docker-milestone SUCCESS in 11m 32s
✔️ ansible-test-sanity-docker-stable-2.9 SUCCESS in 11m 21s
✔️ ansible-test-sanity-docker-stable-2.11 SUCCESS in 9m 11s
✔️ ansible-test-sanity-docker-stable-2.12 SUCCESS in 9m 35s
✔️ ansible-test-units-community-aws-python38 SUCCESS in 6m 08s
✔️ ansible-test-units-community-aws-python39 SUCCESS in 6m 41s
✔️ ansible-test-splitter SUCCESS in 2m 43s
✔️ integration-community.aws-1 SUCCESS in 6m 00s
⚠️ integration-community.aws-2 SKIPPED
⚠️ integration-community.aws-3 SKIPPED
⚠️ integration-community.aws-4 SKIPPED
⚠️ integration-community.aws-5 SKIPPED
⚠️ integration-community.aws-6 SKIPPED
⚠️ integration-community.aws-7 SKIPPED
⚠️ integration-community.aws-8 SKIPPED
⚠️ integration-community.aws-9 SKIPPED
⚠️ integration-community.aws-10 SKIPPED
⚠️ integration-community.aws-11 SKIPPED
⚠️ integration-community.aws-12 SKIPPED
⚠️ integration-community.aws-13 SKIPPED

@softwarefactory-project-zuul softwarefactory-project-zuul bot merged commit a5ded10 into stable-3 Jun 7, 2022
@softwarefactory-project-zuul softwarefactory-project-zuul bot deleted the patchback/backports/stable-3/20f2afd75e506d90a72fb27e4cba3bb09f707494/pr-1221 branch June 7, 2022 13:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue/PR relates to a bug community_review integration tests/integration mergeit Merge the PR (SoftwareFactory) module module new_contributor Help guide this first time contributor plugins plugin (any type) tests tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants