PelionIoT / manifest-tool

A tool for creating and parsing update manifests
Apache License 2.0
11 stars 14 forks source link

Error when aborting an active campaign #7

Closed moonchen closed 5 years ago

moonchen commented 5 years ago

When I try to ctrl-C during a manifest-tool update device, it attempts to delete a campaign, but the campaign needs to be stopped before it can be deleted. The following errors are generated:

^C[CRITICAL] 2019-02-12 17:09:56 - manifesttool.update_device - User Aborted... Cleaning up.
[INFO] 2019-02-12 17:09:56 - manifesttool.update_device - ** Deleting update campaign and manifest **
[CRITICAL] 2019-02-12 17:09:56 - manifesttool.update_device - Cleanup of campaign failed with:
(409) "Conflict" (409)
Reason: Conflict
HTTP response headers: HTTPHeaderDict({'Content-Length': '162', 'Access-Control-Expose-Headers': 'X-Request-ID,Content-Length,Content-Disposition', 'Set-Cookie': 'TS017f188d=01c6170234c1888f130abfb28e4615196173f8134fd5bc00a456775fce2821bc566ff513e4119c74a203b52c03b876fefee1d3bdeb; Path=/', 'Strict-Transport-Security': 'max-age=10886400; includeSubDomains; preload', 'Vary': 'Origin', 'X-Request-ID': '00005c635242d20ae583edf300000002', 'Connection': 'keep-alive', 'Allow': 'GET, PUT, PATCH, DELETE, HEAD, OPTIONS', 'Date': 'Tue, 12 Feb 2019 23:09:54 GMT', 'Access-Control-Allow-Origin': '*', 'Content-Type': 'application/json'})
HTTP response body: {"object":"error","code":409,"type":"conflict","message":"Cannot delete the campaign while in the current phase.","request_id":"00005c634c5fd20ae583edf300000000"}
ciarmcom commented 5 years ago

ARM Internal Ref: IOTUC-898

teetak01 commented 5 years ago

This would need a fix in SDK first: https://github.com/ARMmbed/mbed-cloud-sdk-python/pull/322

evedon commented 5 years ago

CTRL+C is not a supported manifest-tool command. Closing this issue