Review Board 2.0 RC2 (dev)


Allow uri-template arguments to be specified with **kwargs

Review Request #3476 - Created Nov. 6, 2012 and submitted

Information
Steven MacLeod
RBTools
api
Reviewers
rbtools
Allow uri-template arguments to be specified with \*\*kwargs.

The methods for retrieving resources using uri-templates will now check
keyword arguments before the 'values' kwarg.

Previously the replacement keys would be passed in to the 'values'
kwarg, e.g.:
    root.get_review_request(values=\{'review_request_id':1\})
This patch allows for a much cleaner syntax, e.g.:
    root.get_review_request(review_request_id=1)

Additionally, a more descriptive exception is raised when a template
argument isn't specified.
Retrieved review_request, review, and user resources using kwargs to specify
ids. Called methods with missing arguments. Mixed specifying the arguments
with kwargs, and values=\{...\}.
Review request changed
Updated (Nov. 6, 2012, 11:17 a.m.)

Status: Closed (submitted)

Change Summary:

Pushed to api (a45d17accc).