Bug 1127817 - Retrieving consumer history for a consumer that doesn't exist results in a 200 OK
Summary: Retrieving consumer history for a consumer that doesn't exist results in a 20...
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Pulp
Classification: Retired
Component: API/integration
Version: Master
Hardware: Unspecified
OS: Unspecified
medium
low
Target Milestone: ---
: 2.6.0
Assignee: amacdona@redhat.com
QA Contact: Irina Gulina
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-08-07 15:31 UTC by Jeremy Cline
Modified: 2015-02-28 22:14 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-02-28 22:14:30 UTC


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Pulp Redmine 481 None None None Never

Description Jeremy Cline 2014-08-07 15:31:51 UTC
Description of problem:
The docs (https://pulp-dev-guide.readthedocs.org/en/latest/integration/rest-api/consumer/history.html#retrieve-consumer-event-history) say a 404 should be returned if the consumer doesn't exist. However, a 200 and an empty list is actually returned.


Version-Release number of selected component (if applicable): master


How reproducible: always


Steps to Reproduce:
1. curl -i -H "Accept: application/json" -X GET -u admin:admin -k 'https://localhost/pulp/api/v2/consumers/NotARealConsumer/history/'

Actual results:
HTTP/1.1 200 OK
Date: Thu, 07 Aug 2014 15:25:56 GMT
Server: Apache/2.4.10 (Fedora) OpenSSL/1.0.1e-fips mod_wsgi/3.5 Python/2.7.5
Content-Length: 2
Content-Type: application/json

[]

Expected results:
404 Not Found


Additional info:

Comment 1 amacdona@redhat.com 2014-11-04 23:46:35 UTC
https://github.com/pulp/pulp/pull/1284/files

Comment 2 Chris Duryee 2014-12-23 20:53:04 UTC
fixed in pulp 2.6.0-0.2.beta

Comment 3 Irina Gulina 2015-01-13 13:23:17 UTC
>> rpm -qa pulp-server
pulp-server-2.6.0-0.2.beta.el6.noarch

>> curl -i -H "Accept: application/json" -X GET -u admin:admin -k 'https://localhost/pulp/api/v2/consumers/NotARealConsumer/history/'
HTTP/1.1 404 Not Found
Date: Tue, 13 Jan 2015 13:03:43 GMT
Server: Apache/2.2.15 (Red Hat)
Content-Length: 4
Connection: close
Content-Type: application/json

null

Comment 4 Brian Bouterse 2015-02-28 22:14:30 UTC
Moved to https://pulp.plan.io/issues/481


Note You need to log in before you can comment on or make changes to this bug.