ValueError: Invalid value '"Approved"' for parameter 'status'

Bug #401979 reported by Khairul Aizat Kamarudzzaman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Launchpad itself
Invalid
Undecided
Unassigned

Bug Description

Python 2.6.2+ (release26-maint, Jun 19 2009, 15:14:35)
[GCC 4.4.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>>import httplib2
>>>the last one ;-)
>>>httplib.debuglevel = 1
>>>import os, string, sys
>>>from launchpadlib.launchpad import Launchpad, EDGE_SERVICE_ROOT
>>>lp_cache_dir = os.path.abspath('./lpbinding/cache')
>>>launchpad = Launchpad.get_token_and_login('moveteams', EDGE_SERVICE_ROOT, lp_cache_dir)
>>>members = launchpad.people["xxxteam"].members
>>>launchpad.people["ubuntu-xx"].addMember(person=members[0], status="Approved")
......................................................
.......................................................
........................................................
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.6/dist-packages/launchpadlib/resource.py", line 346, in __call__
    **args)
  File "/usr/local/lib/python2.6/dist-packages/wadllib-1.1.1-py2.6.egg/wadllib/application.py", line 591, in build_representation
    media_type, param_values, **kw_param_values)
  File "/usr/local/lib/python2.6/dist-packages/wadllib-1.1.1-py2.6.egg/wadllib/application.py", line 690, in representation
    return definition.bind(param_values, **kw_param_values)
  File "/usr/local/lib/python2.6/dist-packages/wadllib-1.1.1-py2.6.egg/wadllib/application.py", line 801, in bind
    params, param_values, **kw_param_values)
  File "/usr/local/lib/python2.6/dist-packages/wadllib-1.1.1-py2.6.egg/wadllib/application.py", line 169, in validate_param_values
    param_values[name], name, '", "'.join(options)))

Revision history for this message
Khairul Aizat Kamarudzzaman (fenris) wrote :

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.6/dist-packages/launchpadlib/resource.py", line 346, in __call__
    **args)
  File "/usr/local/lib/python2.6/dist-packages/wadllib-1.1.1-py2.6.egg/wadllib/application.py", line 591, in build_representation
    media_type, param_values, **kw_param_values)
  File "/usr/local/lib/python2.6/dist-packages/wadllib-1.1.1-py2.6.egg/wadllib/application.py", line 690, in representation
    return definition.bind(param_values, **kw_param_values)
  File "/usr/local/lib/python2.6/dist-packages/wadllib-1.1.1-py2.6.egg/wadllib/application.py", line 801, in bind
    params, param_values, **kw_param_values)
  File "/usr/local/lib/python2.6/dist-packages/wadllib-1.1.1-py2.6.egg/wadllib/application.py", line 169, in validate_param_values
    param_values[name], name, '", "'.join(options)))
ValueError: Invalid value '"Approved"' for parameter 'status': valid values are: "Proposed", "Approved", "Administrator", "Deactivated", "Expired", "Declined", "Invited", "Invitation declined"

Revision history for this message
Leonard Richardson (leonardr) wrote :

What version of lazr.restfulclient are you using?

>>> import lazr.restfulclient
>>> lazr.restfulclient.__version__

If you're not using 0.9.2, you should upgrade--lazr.restfulclient is giving wadllib bad data. If you are using 0.9.2, this is a problem.

Revision history for this message
Leonard Richardson (leonardr) wrote :

Confirmed that the user was using an old launchpadlib (from a .deb) with a new wadllib (from bzr source).

Changed in launchpad:
status: New → Invalid
Revision history for this message
Khairul Aizat Kamarudzzaman (fenris) wrote :

thanks leonard,

i've removed the one that i get from bzr then reinstall using .deb

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.