-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: None
-
None
-
Service Arch
-
Fully Compatible
-
ALL
-
v8.0
-
Programmability 2024-06-24, Programmability 2024-07-08, Programmability 2024-07-22
We still have some places in the codebase where we invariant on a Status object being OK rather than on the Status itself. Invarianting on the Status itself retains the semantics of failing when it's not OK but adds useful diagnostics in the output, like the error code originally causing the issue.
Convert all invariants that look like invariant(status.isOK()); to invariant(status);. Additionally, write a clang-tidy check to enforce the convention of invarianting on the status directly (might be useful to do this first to find all the offending lines).