Skip to content

Commit 67fac4d

Browse files
authored
Deployment update: explain check_drift return value evaluation (#2507)
Explain what does it mean for values to be false or true, as suggested by @kfrukacz-gs
1 parent ec57ae4 commit 67fac4d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

content/working_with/manager/update-deployment.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,8 @@ The instance will be considered drifted if this operation returns a non-empty va
245245
The {{< param cfy_manager_name >}} doesn't inspect the returned value, so it can be any object. Plugin authors are advised to return a description of all the differences, so that the `update` operation can act upon them.
246246

247247
{{% note title="Warning" %}}
248-
If `check_drift` returns an empty or false value, `update` operations will not run, and even in case of blueprint changes (e.g. if the node properties have changed), the instances will not be updated or reinstalled. Take care to always return a non-empty value if there are _any_ changes to the instances.
248+
If `check_drift` returns an empty or false value, `update` operations will not run, and even in case of blueprint changes (e.g. if the node properties have changed), the instances will not be updated or reinstalled. Take care to always return a non-empty or true value if there are _any_ changes to the instances.
249+
Values are evaluated using Python `bool()` semantics; for example, the empty dict, the number 0, the empty string, the boolean False, or None, are all considered false.
249250
{{% /note %}}
250251

251252
If the `check_drift` operation is not implemented, the instances are only considered drifted if there are relevant blueprint changes (e.g. the node properties have changed).

0 commit comments

Comments
 (0)