@lperoma Both changes are out now, so you can test them.
Agent 0.1.30 waits for the rename/join restart before it runs software, and the snapins wait with it. Agents update themselves to it. After the restart, the first check-in runs the software under the new name. You can drop the name check from your package script. A finished deploy now clears the host’s software status. That is on dev-branch, so update your server to dev-branch to get it.One thing to know: if a user stays logged in on a renamed PC, the restart waits for them to log off, so software waits too. Turn on “Enforce Hostname | AD Join Reboots” on the host to restart after the grace period instead. Details: https://docs.fogproject.org/en/latest/management/web/software/#software-waits-for-a-rename-or-a-domain-join
The log lines for the stale status are still useful if you can grab them.