Return different error codes for `snapcraft upload` responses
Metadata
Current evaluation
No evaluation has been recorded for this issue yet.
Issue body
### Check existing issues
- [x] I've verified that this request isn't described by any existing issues.
### Request
Return different error codes based on the store response from `snapcraft upload`:
- `ready_to_release` -> 0
- `being_processed` -> ?
- `need_manual_review` -> ?
- `processing_upload_delta_error` -> ?
- `processing_error` -> ?
- all other errors unrelated to the store response -> 1
The error codes should be added to the command's reference documentation.
The implementation should be as straightforward as getting `status[code]` and raising the appropriate error code [here](https://github.com/canonical/snapcraft/blob/603626051f05b64f19b683fc3d5ea3edca1b8628/snapcraft/store/client.py#L471-L478).
### The problem it solves
This allows CI workflows to programmatically handle the result of `snapcraft upload`.
Fixes #6076
Evaluation history
No evaluation history available.