Always get labels from Bundle when creating a BundleDeployment #1428
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When a label is modified in the
fleet.yaml
is also modified in theBundle
, but no in theBundleDeployment
BundleDeployment
labels are not being updated when changed in thefleet.yaml
. This is because we just get the labels from theBundle
the first time theBundleDeployment
is created, this is done in the resetDeployment method.This PR always get the labels from the
Bundle
when creating aBundleDeployment
BundleDeployment patch was failing in the integration tests because wrangler was using
application/strategic-merge-patch+json
strategy for the patch. Then I was getting the error:This was happening because I registered the
Bundle
andBundleDeployment
in the client, then wrangler was choosing this strategy here. I fixed this by not registering theBundle
andBundleDeployment
in the client as they are not needed, then I did the same for theBundleDeployment
integration tests here in order to prevent this error in the future.refers to #1153