Skip to content

Fix AfterConfigMap task to handle missing annotations and labels - #2570

Merged
granzoto merged 1 commit into
skupperproject:mainfrom
granzoto:rg-label-defined-check
Sep 10, 2026
Merged

Fix AfterConfigMap task to handle missing annotations and labels #2570
granzoto merged 1 commit into
skupperproject:mainfrom
granzoto:rg-label-defined-check

Conversation

@granzoto

@granzoto granzoto commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

When the label key does not exist yet (because the controller has not reconciled),
Ansible raises an error "dict object has no attribute" instead of treating it as a retry condition.
This doesn't happens in all runs, mainly when we get any performance limitation/slowness in the cluster.
The idea is to improve the way we check if the keys are already available before checking its value.

…ng retry loop

Signed-off-by: Renato Granzoto <rgranzot@redhat.com>
@granzoto
granzoto requested a review from AryanP123 September 9, 2026 20:56
@granzoto granzoto added the test Issue or activity associated with test development and operation label Sep 9, 2026
@coderabbitai

coderabbitai Bot commented Sep 9, 2026

Copy link
Copy Markdown

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Advanced

Run ID: 270272aa-5b5f-449c-b803-61735b2d4102

📥 Commits

Reviewing files that changed from the base of the PR and between 2fd49d7 and cb0bf2f.

📒 Files selected for processing (1)
  • tests/e2e/scenarios/labels-and-annotations/test.yml

Included review availability: Your plan provides up to 4 included reviews per hour; 3 remain after this review.


📝 Walkthrough

Walkthrough

The deployment verification retry conditions now guard custom label and annotation lookups and validate both metadata-level and template-level labels and annotations.

Changes

Label and annotation verification

Layer / File(s) Summary
Expand deployment verification conditions
tests/e2e/scenarios/labels-and-annotations/test.yml
The full_verify conditions now check defined keys before comparison and verify labels and annotations under both metadata and spec.template.metadata.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~2 minutes

Merge Risk: ⚪ Minimal · up to cb0bf

The end-to-end deployment verification now retries when labels or annotations have not yet been reconciled instead of failing on missing metadata, while also validating template metadata. No current merge-blocking risk remains.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly describes the main change: updating the AfterConfigMap task to handle missing deployment annotations and labels during retry evaluation.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Comment @coderabbitai help to get the list of available commands.

@granzoto
granzoto merged commit 02c0cd2 into skupperproject:main Sep 10, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test Issue or activity associated with test development and operation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants