Repository navigation
Description
The ShipBob cancel_wro tool can claim a WRO was cancelled when the HTTP request failed. At the current source, make_shipbob_request returns {"error": response.text, "status_code": response.status_code} for an unsuccessful status. The cancellation handler tests the truthiness of result.get("error"), so an empty error body falls through to **WRO #12345 has been cancelled.**.
I reproduced this offline by executing the two unchanged function bodies with registration decorators removed and request/auth/HTTP transport/response-model stubs (no module startup or live fulfillment calls):
| Synthetic HTTP response | Helper result | Tool output |
|---|---|---|
| 500, empty body | {"error":"","status_code":500} |
Cancellation success |
| 400, empty body | {"error":"","status_code":400} |
Cancellation success |
500, upstream failure |
{"error":"upstream failure","status_code":500} |
Cancellation error |
200, JSON {"id":12345} |
{"id":12345} |
Cancellation success |
Four assertions passed. These are synthetic boundary cases, not an observed production incident or a claim that ShipBob normally returns empty error bodies. ShipBob's error reference identifies 500 as a server error, and its receiving guide defines cancellation as a WRO state transition; an HTTP failure is not evidence that transition completed.
Proposed compact scope: make this plugin's request-error classification independent of message-body truthiness, keep cancellation failure distinct from confirmed success, and add hermetic regression coverage for the empty-body failure plus ordinary failure/success controls. Review the same helper's callers as part of that shared boundary rather than introducing a cancellation-only workaround. No retry or automatic second mutation is proposed. A hard failure should use the existing error path, consistent with the fallback-telemetry contract. Full component/preflight checks have not been run for this source-only report and would be required for a PR.
I checked the ShipBob-related issue/PR results and the actual patches for #8599 (shared models/SDK), #7394 (dependencies), and #10144 (desktop home); none fixes this request/cancellation boundary. Is this standalone integration still supported, and would a $25 bounty be appropriate for this scope under the contribution guide? The amount is proposed, not an existing funded bounty. @josancamon19 @kodjima33
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsIn review
Activity
Nukeys commentedon Sep 11, 2026
Opened PR #13517.
cancel_wronow fails when ShipBob returns an error/status_code key even if the error string is empty.fix(shipbob): treat empty-body HTTP errors as cancel failures (#13517)
test(shipbob-app): keep existing suites green under the tools-auth guard