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

StatusMessage is not always defined in the progress_event #60

Conversation

goneri
Copy link
Member

@goneri goneri commented Apr 18, 2023

With MemoryDB, StatusMessage is not always defined and this trigger an exception
within the existing exception handling block.

With this change we fallback on OperationStatus if StatusMessage
is missing. If none of them are available, we will get a None instead of
an exception.

According to the documentation the presence of these two keys is not guarantee.
They are both identified as optional (Required: No).

See: https://docs.aws.amazon.com/cloudcontrolapi/latest/APIReference/API_ProgressEvent.html

@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.
https://ansible.softwarefactory-project.io/zuul/buildset/8f4201a2d38641398d2b216793a6ed86

✔️ ansible-galaxy-importer SUCCESS in 3m 27s
✔️ build-ansible-collection SUCCESS in 9m 47s
ansible-test-sanity-docker-devel FAILURE in 7m 23s (non-voting)
ansible-test-sanity-docker-milestone FAILURE in 7m 17s (non-voting)
✔️ ansible-test-sanity-docker-stable-2.11 SUCCESS in 11m 04s
✔️ ansible-test-sanity-docker-stable-2.12 SUCCESS in 8m 12s
✔️ ansible-test-sanity-docker-stable-2.13 SUCCESS in 10m 06s
✔️ ansible-test-sanity-docker-stable-2.14 SUCCESS in 9m 18s
✔️ tox-cloud-refresh-examples-amazon SUCCESS in 9m 30s

@goneri goneri requested review from gravesm and alinabuzachis April 19, 2023 15:38
Copy link
Member

@gravesm gravesm left a comment

Choose a reason for hiding this comment

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

Would you mind adding a changelog? Otherwise, looks good.

With MemoryDB, `StatusMessage` is not always defined and this trigger an exception
within the existing exception handling block.

With this change we fallback on `OperationStatus` if `StatusMessage`
is missing. If none of them are available, we will get a `None` instead of
an exception.

According to the documentation the presence of these two keys is not guarantee.
They are both identified as optional (`Required: No`).

See: https://docs.aws.amazon.com/cloudcontrolapi/latest/APIReference/API_ProgressEvent.html
@goneri goneri force-pushed the StatusMessage-is-not-always-defined-in-the-progress_event_8245 branch from ae33577 to 84f3ec2 Compare April 19, 2023 16:25
@goneri goneri requested a review from gravesm April 19, 2023 16:26
@softwarefactory-project-zuul
Copy link
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/9dec616ffb7d4443b36f4ac922c75b1b

ansible-galaxy-importer RETRY_LIMIT in 4m 54s
✔️ build-ansible-collection SUCCESS in 10m 06s
ansible-test-sanity-docker-devel FAILURE in 9m 28s (non-voting)
ansible-test-sanity-docker-milestone FAILURE in 7m 59s (non-voting)
✔️ ansible-test-sanity-docker-stable-2.11 SUCCESS in 10m 51s
✔️ ansible-test-sanity-docker-stable-2.12 SUCCESS in 8m 37s
✔️ ansible-test-sanity-docker-stable-2.13 SUCCESS in 8m 06s
✔️ ansible-test-sanity-docker-stable-2.14 SUCCESS in 9m 51s
✔️ tox-cloud-refresh-examples-amazon SUCCESS in 10m 02s

@goneri goneri merged commit 15841dc into ansible-collections:main Apr 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants