A city IT integration catches an unrecoverable 4xx from a Cisco API inside a helper and returns an empty “success” object so callers keep running. What is the correct design instead?
Select an answer to reveal the explanation.
Short Explanation
Hiding a broken pipe under the sink does not fix the leak—it just floods the basement later. Catching an unrecoverable Cisco API error and faking success hides the failure; propagate it so the caller can stop or compensate.
Full Explanation
Unrecoverable client errors from a Cisco API must remain visible to the next layer. Returning an empty success object converts a failed hop into a false happy path and blocks stop, retry-alternate, or compensation logic. Correct control flow propagates an exception, Result err, or explicit failure status while still avoiding raw stack dumps as the only contract.