Closed gernot-h closed 1 year ago
If you try to download a non-existing attachment, we today create a file with the JSON error messages as we ignore the HTTP status.
> sw360.download_release_attachment("test.txt", "111","222") > cat test.txt {"timestamp":"2023-07-30T19:42:21.815136Z","status":404,"error":"Not Found","message":"Release does not exists! id=111"}
Instead, it should raise SW360Error as for any other failed operation, e.g.
SW360Error
> sw360.get_attachment("222") --------------------------------------------------------------------------- SW360Error Traceback (most recent call last) [...] SW360Error: <Response [404]>
If you try to download a non-existing attachment, we today create a file with the JSON error messages as we ignore the HTTP status.
Instead, it should raise
SW360Error
as for any other failed operation, e.g.