Currently, the error log generated by constructErrorStatus() can currently be misleading. For example, it may produce the following message:
Unable to start new balancer operation because this shard is currently donating range 'min: { _id: "atlas-ffavf6-shard-1" } - max: { _id: "atlas-ffavf6-shard-1" }'
which can be interpreted as there is an ongoing migration with the same min-max bounds (which will never succeed). The migration sets min and max bounds correctly in the corresponding BSON objects, e.g., 'min: { _id: "atlas-ffavf6-shard-1" }{} and max: { _id: "atlas-ffavf6-shard-1\u0000"} for canary collections. However, when logging with constructErrorStatus, we only concatenate the string representation of the stored BSON objects, which makes the NUL control character \u0000 disappear and therefore the two different boundaries look identical.
As part of this ticket, we should fix this misleading log message.