Mender client sending back fail status after Download_Enter fail, contradicts documentation

I’m using Download_Enter scripts in my implementation to ask users if they would like to install the update. If the user refuses the update, the script returns 1. I read in the documentation that:

Returning 1 in any of the Download_Enter scripts will cause the client to abort the update and go back to Idle, but it will not report failure to the server. Therefore the deployment will be retried on the next polling cycle. This behavior may change in the future.

Somehow this does not seem to be the case, but maybe I did something wrong. Here’s the log from one of the update where the user selected “Later” instead of “Update”:

2026-07-08 10:26:08.166 +0000 UTC info: Running Mender client 5.0.2
2026-07-08 10:26:08.166 +0000 UTC info: Deployment with ID 1bf67394-a718-45a8-9681-85690c2a951a started.
2026-07-08 10:26:08.168 +0000 UTC info: Sending status update to server
2026-07-08 10:26:08.33 +0000 UTC info: Running State Script: /etc/mender/scripts/Download_Enter_01_maybepopup
2026-07-08 10:26:08.365 +0000 UTC info: Collected output (stderr) while running script: Running as unit: run-r71651bb5fd514a3c8f3234cd51236c37.service; invocation ID: b63e56a0d2d547b0a6bc878a7d399024
2026-07-08 10:26:08.366 +0000 UTC info: Running State Script: /etc/mender/scripts/Download_Enter_02_waituseraccept
2026-07-08 10:26:08.399 +0000 UTC info: Collected output (stderr) while running script: Running as unit: run-r5ee2a59c844e44b6b3fd5b04a36f4826.service; invocation ID: 6777c4aee0584e8aa4a31fe55e2305e9
2026-07-08 10:26:11.746 +0000 UTC info: Collected output (stderr) while running script: Finished with result: exit-code
2026-07-08 10:26:11.746 +0000 UTC info: Collected output (stderr) while running script: Main processes terminated with: code=exited, status=1/FAILURE
2026-07-08 10:26:11.746 +0000 UTC info: Collected output (stderr) while running script: Service runtime: 3.344s
2026-07-08 10:26:11.746 +0000 UTC info: Collected output (stderr) while running script: CPU time consumed: 16ms
2026-07-08 10:26:11.748 +0000 UTC info: Collected output (stderr) while running script: mender-state: user declined the update notification
2026-07-08 10:26:11.748 +0000 UTC error: Received error: (NonZero exit code error: Received error code: 1) when running the State Script scripts DownloadEnter
2026-07-08 10:26:11.75 +0000 UTC info: Running State Script: /etc/mender/scripts/Download_Error_01_popup
2026-07-08 10:26:11.781 +0000 UTC info: Collected output (stderr) while running script: Running as unit: run-rf71bc68cc990429a9f7d8d6979379545.service; invocation ID: c72dcf3a21aa406bafe1aa905a1ad09c
2026-07-08 10:26:11.809 +0000 UTC info: Collected output (stderr) while running script: Finished with result: exit-code
2026-07-08 10:26:11.809 +0000 UTC info: Collected output (stderr) while running script: Main processes terminated with: code=exited, status=1/FAILURE
2026-07-08 10:26:11.809 +0000 UTC info: Collected output (stderr) while running script: Service runtime: 24ms
2026-07-08 10:26:11.809 +0000 UTC info: Collected output (stderr) while running script: CPU time consumed: 16ms
2026-07-08 10:26:11.811 +0000 UTC info: Collected output (stderr) while running script: mender-state: update was not finally accepted; suppressing download failure notification
2026-07-08 10:26:11.812 +0000 UTC info: Sending status update to server

As you can see the Download_Enter_02_waituseraccept script returned 1, and following that the Download_Error_01_popup script returned 0. I would have thought (based on the documentation) that the status would not have been sent back to the server but it did and the deployment was then marked as failed… Any idea? Thanks!

Version:

# mender-update --version
5.0.2