Bug 841688 - repo groups PUT causes 500
repo groups PUT causes 500
Status: CLOSED CURRENTRELEASE
Product: Pulp
Classification: Community
Component: API/integration (Show other bugs)
unspecified
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Jason Connor
Preethi Thomas
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-07-19 17:14 EDT by Michael Hrivnak
Modified: 2014-03-30 21:39 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-01-07 09:10:03 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Michael Hrivnak 2012-07-19 17:14:56 EDT
Description of problem:

pulp.server.webservices.controllers.repo_groups.RepoGroupResource.PUT tries to pass two positional arguments to RepoGroupManager.update_repo_group, but that method is only willing to accept one of them.  As a result, a PUT request to that controller returns 500.

http://git.fedorahosted.org/git/?p=pulp.git;a=blob;f=platform/src/pulp/server/webservices/controllers/repo_groups.py;h=ca3804a4e3066a6d0f26be7dd15950057974c4c8;hb=HEAD#l116

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

latest (git @ca3804a4)
Comment 1 Jay Dobies 2012-07-24 10:12:55 EDT
Fixed as part of commit:


commit 50d9a547a54b0567ce28b09a324fd2468e6180ee
Author: Jay Dobies <jason.dobies@redhat.com>
Date:   Mon Jul 23 14:36:11 2012 -0400

    Unit tests for repo group CRUD REST controllers

platform/src/pulp/server/dispatch/constants.py
platform/src/pulp/server/webservices/controllers/repo_groups.py
platform/src/pulp/server/webservices/controllers/repositories.py
platform/test/unit/test_repo_group_controller.py
Comment 2 Jeff Ortel 2012-08-02 09:48:21 EDT
build: 0.320.
Comment 3 Preethi Thomas 2012-08-13 15:16:24 EDT
verified
[root@preethi-el6-pulp ~]# rpm -q pulp-rpm-server
pulp-rpm-server-0.0.321-1.el6.noarch

>>> pic.PUT('/v2/repo_groups/mygroup/',body={ "display_name": "Demo Group"})
Request Body
{
  "display_name": "Demo Group"
}
Response Body
{
  "scratchpad": null, 
  "display_name": "Demo Group", 
  "description": null, 
  "_ns": "repo_groups", 
  "notes": {}, 
  "repo_ids": [], 
  "_id": {
    "$oid": "50256b11196f455d6800007f"
  }, 
  "id": "mygroup", 
  "_href": "/pulp/api/v2/repo_groups/mygroup/"
}
(200, {u'scratchpad': None, u'display_name': u'Demo Group', u'description': None, u'_ns': u'repo_groups', u'notes': {}, u'repo_ids': [], u'_id': {u'$oid': u'50256b11196f455d6800007f'}, u'id': u'mygroup', u'_href': u'/pulp/api/v2/repo_groups/mygroup/'})
>>>
Comment 4 Preethi Thomas 2013-01-07 09:10:03 EST
Pulp 2.0 released.

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