Secrets Manager Client: Raise error when OpenBao API response includes warnings
To ensure that we catch unexpected failures in during development and testing, we should raise an error when the OpenBao API response includes a warning. Currently, this is ignored by the secrets manager client and so some test failures can be hard to debug.
Development plan
Warning Categorization
- Audit OpenBao documentation for all possible warning types
- Create two lists:
- Warnings safe to ignore (log only)
- Warnings requiring error/blocking
- Implement warning detection in OpenBao response handler
- Apply categorization logic step 2
- We can check if there is a warning in Openbao response Here by
body["warnings"] - For safe warnings: log and continue
- For critical warnings: raise appropriate error with clear message
- Add tests for each warning scenario
Validation steps
- Review warning categorization list for completeness
- Trigger each warning type in test environment
- Verify safe warnings are logged but don't block operations
- Confirm critical warnings display error and prevent action
- Check logs contain all expected warning details
Edited by Dmytro Biryukov