Project

Profile

Help

Issue #4472

Relative_path error when uploading a file

Added by daviddavis over 1 year ago. Updated 10 months ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Sprint/Milestone:
-
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Platform Release:
OS:
Triaged:
No
Groomed:
No
Sprint Candidate:
No
Tags:
Sprint:
Quarter:

Description

If you follow the docs to upload a file and create an rpm, you get the following error:

HTTP/1.1 400 Bad Request
Allow: GET, POST, HEAD, OPTIONS
Content-Length: 46
Content-Type: application/json
Date: Tue, 26 Feb 2019 09:27:59 GMT
Server: WSGIServer/0.2 CPython/3.7.2
Vary: Accept, Cookie
X-Frame-Options: SAMEORIGIN

{
    "_relative_path": [
        "This field is required."
    ]
}

We need to update our code based on https://pulp.plan.io/issues/4394.

clipboard-201912071555-kiqre.png (2.45 KB) clipboard-201912071555-kiqre.png Anonymous, 12/07/2019 11:25 AM
250

Related issues

Related to Pulp - Issue #4394: Content serializer validate should ensure a saveable objectCLOSED - CURRENTRELEASE<a title="Actions" class="icon-only icon-actions js-contextmenu" href="#">Actions</a>
Related to RPM Support - Issue #4446: multiple test failures on master branchCLOSED - CURRENTRELEASE<a title="Actions" class="icon-only icon-actions js-contextmenu" href="#">Actions</a>

Associated revisions

Revision 060627d0 View on GitHub
Added by daviddavis over 1 year ago

Fixing package upload

Fixing package upload after changes from https://pulp.plan.io/issues/4394.

fixes #4472 https://pulp.plan.io/issues/4472

History

#1 Updated by daviddavis over 1 year ago

  • Related to Issue #4394: Content serializer validate should ensure a saveable object added

#2 Updated by daviddavis over 1 year ago

I'm trying to update this code but I have a couple questions here:

https://pulp-rpm.readthedocs.io/en/latest/workflows/upload.html#create-rpm-content-from-an-artifact

It seems like relative_path and filename are redundant and should be combined? Moreover, I don't see a filename field in the api docs nor on the PackageSerializer.

I'm also wondering if we should just remove this endpoint and just use the one shot uploader?

Edit: Filed separate issue about filename param: https://pulp.plan.io/issues/4473

#3 Updated by ttereshc over 1 year ago

  • Related to Issue #4446: multiple test failures on master branch added

#4 Updated by daviddavis over 1 year ago

  • Status changed from ASSIGNED to MODIFIED

#6 Updated by bmbouter over 1 year ago

  • Tags deleted (Pulp 3)

#8 Updated by ttereshc 10 months ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Please register to edit this issue

Also available in: Atom PDF