Clean up and improve upon the rbt patch JSON output.

Review Request #12173 — Created March 17, 2022 and submitted

Information

RBTools
master

Reviewers

The rbt patch --json output has had some cleanups designed to help
identify failed patches, to avoid failure on warnings, and to add
consistency with other JSON updates.

When a patch fails to apply, failed_patch_num will now be set to the
patch number. This can help with debugging the application of multiple
patches.

The total number of patches is now recorded in total_patches, rather
than n_patches.

review_request has been renamed to review_request_id, and
review_request_url has been added. review_request_id is now
an integer, rather than a string.

If the working directory is clean, we now warn, rather than erroring
out. Previously, the error would cause status to be failed, even if
the patch was successful. Reducing this to a warning avoids this
problem.

Tested applying patches and triggering the various errors. Checked to
make sure I was getting the payloads I expected in each case.

Tested with an unclean working directory. Verified I got a warning, but
it still completed successfully.

Summary ID
Clean up and improve upon the rbt patch JSON output.
The `rbt patch --json` output has had some cleanups designed to help identify failed patches, to avoid failure on warnings, and to add consistency with other JSON updates. When a patch fails to apply, `failed_patch_num` will now be set to the patch number. This can help with debugging the application of multiple patches. The total number of patches is now recorded in `total_patches`, rather than `n_patches`. `review_request` has been renamed to `review_request_id`, and `review_request_url` has been added. If the working directory is clean, we now warn, rather than erroring out. Previously, the error would cause `status` to be `failed`, even if the patch was successful. Reducing this to a warning avoids this problem.
3c5a3d7acd4aab0e74fb260eb7d83330e5a37c2c
chipx86
david
  1. Ship It!
  2. 
      
chipx86
Review request changed
Status:
Completed
Change Summary:
Pushed to release-3.x (81b67aa)