RBTools 0.5.1 Release Notes¶
Release date: May 30, 2013
Improved the readability of
Each review request output is now indented, causing the IDs and draft indicators to line up.
--repository-typeoption to most commands.
rbtcommands which work with the repository, including
post-review, now have a
--repository-typeoption. This option allows the user to specify a particular repository type to be used.
This type can also be set for a repository by setting
This option will cause
post-reviewto print the valid repository types and then exit. This can be used to see valid values for the new
Added a new
rbt list-repo-typescommand will print the valid repository types. These values can be used for the new
Third-parties can now write new SCM support by creating Python packages leveraging Python entry points. SCMClient subclasses can be registered through the
All our SCMClients are registered this way as well.
API Client Changes¶
Added an API Client method for retrieving resources from a path.
The RBClient now has a
get_pathmethod, which will accept a path and retrieve the API resource at that path. For example, a path of
/review-requests/123/would retrieve the resource at
get_or_create_draftmethod to the API.
This new resource-specific method for Review Request Resources allows creating/retrieving a Review Request Draft resource. Previously, this was only accessible after first uploading a diff, which is no longer required.
Restructured the API Client internally.
Instead of wrapping everything and hiding resources inside of various Transport objects, Resource objects are now returned to the user. The Transport no longer serves as an all-wrapping, interface to and between everything, super object, but as a simple interface to the Review Board server.
Resource method calls which return HttpRequests are now decorated, which serves as the new wrapping mechanism. The decorator captures calls to these methods, and passes the internal method, and arguments, off to the Transport to be executed. The new simpler Transport now only provides a few core methods; primarily it needs to be able to massage the provided arguments, call the method, and deal with the returned HttpRequest in a suitable manner. This should make writing a new synchronous Transport simple.
Now that proper Resource objects are returned, API users can rely on checking class types using
isinstance()to differentiate between item and list resources, etc.
Additionally, dictionary or list fields returned from a resource use standard class types, regardless of the transport used.
Fixed crash when copying old post-review cookies for use with
An edge case existed where copying old post-review cookies to be used with the
rbtcommand would cause a crash. Cookies will now be copied properly.
rbtcommands will now properly generate diffs with moved files.
rbtcommands were not properly checking the capabilities of the Review Board server, and always assumed there was no support for moved file diffs. The capabilities of the server are now properly checked, and diffs with moved files will be generated when appropriate.
Fixed references to non-existent variables in
rbt patchcommand would immediately crash, making it unusable. The command now functions properly.
Patch by Adam Collard.
rbt postfor Perforce repositories.
When using rbt post with Perforce, posting an update to a review request using a change number would result in an error. We now properly update the review request instead of failing.
rbt postand rbt diff for Subversion and Bazaar.
A number of cases causing crashes when using
rbtwith Subversion and Bazaar have been fixed.
rbtwhen used for Perforce paths.
Posting a code review using a path no longer results in a crash.
Patch by Damian Johnson (Bug #2881).
Fixed error handling when posting a review request.
If an unhandled error code was returned from the server, the process would just quit without any useful indication of what went wrong. We now use the error message from the server.
On top of this,
post-reviewnow check against the proper error code for the Empty Diff error.
This makes life simpler for packagers, since most packaging tools will ensure that the appropriate packages are available on the system. Additionally, most packaging tools prefer not to rely on network access (since it can mean that identical rebuilds cannot be performed).
Patch by Stephen Gallagher.