Actions
Issue #3965
closedCreated Resource schema generated incorrectly
Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Category:
-
Sprint/Milestone:
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Platform Release:
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Sprint:
Sprint 42
Quarter:
Description
I noticed that the JSON returned has a list of HREFs for created resources. However, the OpenAPI schema states that this should be a list of 'Created Resource' objects that have multiple fields.
>>> api.tasks_read('/pulp/api/v3/tasks/487f9f07-5056-413f-a7f6-1a59117e2b66/')
{'created': datetime.datetime(2018, 9, 2, 16, 55, 46, 464597, tzinfo=tzlocal()),
'created_resources': [{'created': None, 'href': None, 'id': None}],
'error': None,
....
}
$ http :8000/pulp/api/v3/tasks/487f9f07-5056-413f-a7f6-1a59117e2b66/
{
"_href": "/pulp/api/v3/tasks/487f9f07-5056-413f-a7f6-1a59117e2b66/",
"created": "2018-09-02T16:55:46.464597Z",
"created_resources": [
"/pulp/api/v3/repositories/9/versions/1/"
],
...
}
Related issues
Added by dkliban@redhat.com over 6 years ago
Added by dkliban@redhat.com over 6 years ago
Revision f9d6a287 | View on GitHub
Problem: OpenAPI schema for created resource contains fields
Solution: remove the non-existing fields from the serializer
Updated by dkliban@redhat.com over 6 years ago
- Status changed from ASSIGNED to POST
Updated by dkliban@redhat.com over 6 years ago
- Status changed from POST to MODIFIED
Applied in changeset pulp|f9d6a287ab87557bbe1970e1b5fd3ae11f75d8e7.
Updated by kersom about 6 years ago
- Related to Test #4123: Test the generated API binds added
Updated by bmbouter about 5 years ago
- Status changed from MODIFIED to CLOSED - CURRENTRELEASE
Actions
Problem: OpenAPI schema for created resource contains fields
Solution: remove the non-existing fields from the serializer
closes: #3965 https://pulp.plan.io/issues/3965