Issue #750
closedCall to remove a nonexisting importer results in a misleading 404 (missing repo)
Description
Description
A call to remove a nonexisting importer correctly returns a 404, however the information is misleading. In this case the repo exists, the importer does not, however it suggests that the repo does not exist and makes no mention about the importer.
Actual Results
$ curl -s -H "Accept: application/json" -H "WebFrameworkSwitch: webpy" -X DELETE -k -u admin:admin https://localhost/pulp/api/v2/repositories/test/importers/fake/ | python -mjson.tool
{
"_href": "/pulp/api/v2/repositories/test/importers/fake/",
"error": {
"code": "PLP0009",
"data": {
"resources": {
"repository": "test"
}
},
"description": "Missing resource(s): repository=test",
"sub_errors": []
},
"error_message": "Missing resource(s): repository=test",
"exception": null,
"http_request_method": "DELETE",
"http_status": 404,
"resources": {
"repository": "test"
},
"traceback": null
}
Expected Results
$ curl -s -H "Accept: application/json" -H "WebFrameworkSwitch: webpy" -X DELETE -k -u admin:admin https://localhost/pulp/api/v2/repositories/test/importers/fake/ | python -mjson.tool
{
"_href": "/pulp/api/v2/repositories/test/importers/fake/",
"error": {
"code": "PLP0009",
"data": {
"resources": {
"repository": "test"
}
},
"description": "Missing resource(s): importer_id=fake",
"sub_errors": []
},
"error_message": "Missing resource(s): importer_id=fake",
"exception": null,
"http_request_method": "DELETE",
"http_status": 404,
"resources": {
"repository": "test"
},
"traceback": null
}
Note
This problem occurs in the manager so it will not be fixed by the django work.
Updated by dkliban@redhat.com about 9 years ago
- Status changed from NEW to ASSIGNED
- Assignee set to amacdona@redhat.com
- Severity set to Medium
- Triaged changed from No to Yes
- Platform Release set to 2.7.0
Updated by amacdona@redhat.com about 9 years ago
- Status changed from ASSIGNED to NEW
- Assignee deleted (
amacdona@redhat.com)
This was mistakenly assigned to me. This will not be fixed by the django conversion.
Updated by ipanova@redhat.com almost 9 years ago
- Status changed from NEW to ASSIGNED
- Assignee set to ipanova@redhat.com
Updated by ipanova@redhat.com almost 9 years ago
- Status changed from ASSIGNED to POST
- Platform Release set to 2.7.1
Updated by ipanova@redhat.com almost 9 years ago
Please, during verification of this bug also check:
- delete/get/update invalid importer_id when repo has no importers,
- delete/get/update invalid importer_id when repo has different importer from the provided one
Added by ipanova@redhat.com almost 9 years ago
Added by ipanova@redhat.com almost 9 years ago
Revision cb26d892 | View on GitHub
Fixing get, update, delete call when non existent importer is provided.
Updated by ipanova@redhat.com almost 9 years ago
- Status changed from POST to MODIFIED
- % Done changed from 0 to 100
Applied in changeset pulp|cb26d8923c8adb6c29686d0554375b2c7024da52.
Updated by amacdona@redhat.com over 8 years ago
- Platform Release changed from 2.7.1 to 2.7.2
Updated by dkliban@redhat.com about 8 years ago
- Status changed from MODIFIED to 5
Updated by semyers almost 8 years ago
- Status changed from 5 to CLOSED - CURRENTRELEASE
- Platform Release changed from 2.7.2 to 2.7.0
Fixing get, update, delete call when non existent importer is provided.
closes #750 https://pulp.plan.io/issues/750