kubernetes / kubernetes/kops

RenderAWS issues with removing substructs

Open
#11,260 6 comments 0 reactions 0 assignees View on GitHub
lifecycle/frozen
Dominant language
Go
Stars
16.7k
Forks
4.7k
Avg merge
17h 21m
Merged PRs (30d)
68

Description

The design of the `changes` parameter in `RenderAWS` leads to latent bugs where `RenderAWS` is unable to reconcile the removal of a substruct. An example of this is #11255.

It is easy to write code to test whether a subfield of `changes` is `== nil` in order to determine whether a change needs to be made. But if the expected is `nil` and actual is non-`nil` such naive code will miss that a change is needed.

This is exacerbated because we don't have a framework for methodically unit testing whether `RenderAWS` receivers are able to reconcile different possible actuals to expecteds.

Contributor guide

Open the contributing guide

Research direction

Start by reading the RenderAWS entry point and the example in #11255, then inspect how the changes parameter represents absent and non-nil substructs. Determine the expected reconciliation cases and the unit-testing framework needed to cover actuals against expecteds, including substruct removal.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, go
Domain
infrastructure, testing-qa
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.