🚀 Enhancements
fix(vendor): show descriptive explanation instead of bare count in error @osterman (#2103)
## what- Vendor pull failures now show descriptive error explanations listing failed component names instead of just a bare integer count
- When 1 of 7 components fails, the error now shows "Failed to vendor 1 of 7 components: my-vpc" in the explanation section instead of just "1"
- Added tracking of failed package names in the model and proper error builder usage with
WithExplanation()
why
Error messages showed "## Explanation\n1" which was confusing and unhelpful. Users couldn't tell which component failed or how many total components were being vendored. The fix uses the error builder pattern to provide meaningful context about what went wrong.
references
- Implements error handling best practices from Atmos error builder pattern
- Adds regression tests to prevent future occurrences of bare integer explanations
Summary by CodeRabbit
-
Bug Fixes
- Vendoring failure messages now include a clear explanation and an explicit list/count of which components failed for easier troubleshooting.
- No changes to public APIs or other user-facing behavior beyond improved messaging.
-
Tests
- Added tests to ensure error formatting and failed-component tracking behave as expected.