Project

Profile

Help

Issue #3304

closed

Repository Version content can be added infinite number of times

Added by dkliban@redhat.com almost 7 years ago. Updated almost 5 years ago.

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 32
Quarter:

Description

Both the repository version API and the repository version content API report that the same unit is in a repository version twice.

(pulp) [vagrant@pulp3 pulp]$ http GET $REPO_HREF'versions/4/content/'
HTTP/1.0 200 OK
Allow: GET, HEAD, OPTIONS
Content-Length: 990
Content-Type: application/json
Date: Fri, 19 Jan 2018 14:06:24 GMT
Server: WSGIServer/0.2 CPython/3.6.3
Vary: Accept, Cookie
X-Frame-Options: SAMEORIGIN

{
    "next": null,
    "previous": null,
    "results": [
        {
            "_href": "http://localhost:8000/api/v3/content/file/2decf959-c6c0-4384-91d5-e8d8fe76a7c0/",
            "artifacts": {
                "test.iso": "http://localhost:8000/api/v3/artifacts/133e0e7e-903e-4349-94aa-2ca9c0221b54/"
            },
            "digest": "582f1729b0c15eacbb7d02a553c0a96a39f817135c15ac4190aef96e45c4b65d",
            "notes": {},
            "path": "test.iso",
            "type": "file"
        },
        {
            "_href": "http://localhost:8000/api/v3/content/file/b2970189-ccff-46aa-89ca-6bebc2e70a18/",
            "artifacts": {
                "test2.iso": "http://localhost:8000/api/v3/artifacts/b9b7380b-a303-4e2d-a748-0e874ea89275/"
            },
            "digest": "042c259d546331588e1dff83a46f62a27fb7cf3de4050924470d99fd8d2a046f",
            "notes": {},
            "path": "test2.iso",
            "type": "file"
        },
        {
            "_href": "http://localhost:8000/api/v3/content/file/f179c296-129e-4e14-bf58-519162b59d77/",
            "artifacts": {
                "test3.iso": "http://localhost:8000/api/v3/artifacts/677dd1fc-f3db-41c6-900c-0a770e08f0a5/"
            },
            "digest": "f56e08898287e60b3169392351e9296bbe28417db1f8e34e8058d124be89b93a",
            "notes": {},
            "path": "test3.iso",
            "type": "file"
        }
    ]
}
(pulp) [vagrant@pulp3 pulp]$ http GET $REPO_HREF'versions/5/content/'
HTTP/1.0 200 OK
Allow: GET, HEAD, OPTIONS
Content-Length: 1307
Content-Type: application/json
Date: Fri, 19 Jan 2018 14:06:29 GMT
Server: WSGIServer/0.2 CPython/3.6.3
Vary: Accept, Cookie
X-Frame-Options: SAMEORIGIN

{
    "next": null,
    "previous": null,
    "results": [
        {
            "_href": "http://localhost:8000/api/v3/content/file/2decf959-c6c0-4384-91d5-e8d8fe76a7c0/",
            "artifacts": {
                "test.iso": "http://localhost:8000/api/v3/artifacts/133e0e7e-903e-4349-94aa-2ca9c0221b54/"
            },
            "digest": "582f1729b0c15eacbb7d02a553c0a96a39f817135c15ac4190aef96e45c4b65d",
            "notes": {},
            "path": "test.iso",
            "type": "file"
        },
        {
            "_href": "http://localhost:8000/api/v3/content/file/b2970189-ccff-46aa-89ca-6bebc2e70a18/",
            "artifacts": {
                "test2.iso": "http://localhost:8000/api/v3/artifacts/b9b7380b-a303-4e2d-a748-0e874ea89275/"
            },
            "digest": "042c259d546331588e1dff83a46f62a27fb7cf3de4050924470d99fd8d2a046f",
            "notes": {},
            "path": "test2.iso",
            "type": "file"
        },
        {
            "_href": "http://localhost:8000/api/v3/content/file/b2970189-ccff-46aa-89ca-6bebc2e70a18/",
            "artifacts": {
                "test2.iso": "http://localhost:8000/api/v3/artifacts/b9b7380b-a303-4e2d-a748-0e874ea89275/"
            },
            "digest": "042c259d546331588e1dff83a46f62a27fb7cf3de4050924470d99fd8d2a046f",
            "notes": {},
            "path": "test2.iso",
            "type": "file"
        },
        {
            "_href": "http://localhost:8000/api/v3/content/file/f179c296-129e-4e14-bf58-519162b59d77/",
            "artifacts": {
                "test3.iso": "http://localhost:8000/api/v3/artifacts/677dd1fc-f3db-41c6-900c-0a770e08f0a5/"
            },
            "digest": "f56e08898287e60b3169392351e9296bbe28417db1f8e34e8058d124be89b93a",
            "notes": {},
            "path": "test3.iso",
            "type": "file"
        }
    ]
}
(pulp) [vagrant@pulp3 pulp]$ http GET $REPO_HREF'versions/5/'
HTTP/1.0 200 OK
Allow: GET, DELETE, HEAD, OPTIONS
Content-Length: 545
Content-Type: application/json
Date: Fri, 19 Jan 2018 14:09:52 GMT
Server: WSGIServer/0.2 CPython/3.6.3
Vary: Accept, Cookie
X-Frame-Options: SAMEORIGIN

{
    "_added_href": "http://localhost:8000/api/v3/repositories/c1206a9d-b03a-4198-8c45-e6ad6ed073bb/versions/5/added_content/",
    "_content_href": "http://localhost:8000/api/v3/repositories/c1206a9d-b03a-4198-8c45-e6ad6ed073bb/versions/5/content/",
    "_href": "http://localhost:8000/api/v3/repositories/c1206a9d-b03a-4198-8c45-e6ad6ed073bb/versions/5/",
    "_removed_href": "http://localhost:8000/api/v3/repositories/c1206a9d-b03a-4198-8c45-e6ad6ed073bb/versions/5/removed_content/",
    "content_summary": {
        "file": 4
    },
    "created": "2018-01-19T14:05:51.829350Z",
    "number": 5
}

Also available in: Atom PDF