Repository navigation
Conversation
A manifest whose service key is a scalar raised AttributeError in both extension loops, which fell outside the structure-error handler and re-raised — crashing resolve-compose-stack.sh even with --skip-broken. Validate the service mapping explicitly so the existing parse-error path reports it and honors --skip-broken.
|
I tested this against a manifest whose stdout is empty, so no compose flags come out for any service. Every |
|
Correction to my comment above: I tested without |
Summary
Fixes #5712.
resolve-compose-stack.shcrashed with an uncaughtAttributeErrorwhen a manifest'sservicekey was not a mapping (e.g.service: not-a-mappingorservice: 42), in both the bundled-extension and user-extension loops:manifest.get("service", {})returns the scalar, soservice.get("gpu_backends", ...)raisesAttributeErrorAttributeErroris not covered by the structure-error handler (KeyError,TypeError), so it fell through toraise— a full Python traceback and exit 1 even with--skip-brokenThe fix validates
isinstance(service, dict)immediately after reading the key in both loops, raisingTypeErrorwith a descriptive message. That routes through the existing structure-error path:ERROR: Failed to parse manifest …is printed, and--skip-brokenskips the extension as intended.Reproduction on
public-beta(both loops):Validation
tests/test-resolve-compose-resilient.shcovers a scalarservicein both the bundled-extension and user-extension loops:--skip-brokenmust exit 0, print the structure-error message, and produce no tracebackbash -nclean; ShellCheck reports no new findings on changed lines