Merge lp://qastaging/~wallyworld/lazr.restfulclient/relative-url-fix-681767 into lp://qastaging/lazr.restfulclient

Proposed by Ian Booth
Status: Merged
Approved by: Curtis Hovey
Approved revision: 124
Merged at revision: 124
Proposed branch: lp://qastaging/~wallyworld/lazr.restfulclient/relative-url-fix-681767
Merge into: lp://qastaging/lazr.restfulclient
Diff against target: 154 lines (+29/-11)
5 files modified
.bzrignore (+1/-0)
src/lazr/restfulclient/NEWS.txt (+6/-0)
src/lazr/restfulclient/docs/entries.txt (+9/-0)
src/lazr/restfulclient/resource.py (+12/-10)
src/lazr/restfulclient/version.txt (+1/-1)
To merge this branch: bzr merge lp://qastaging/~wallyworld/lazr.restfulclient/relative-url-fix-681767
Reviewer Review Type Date Requested Status
Curtis Hovey (community) code Approve
Review via email: mp+102050@code.qastaging.launchpad.net

Commit message

Fix ServiceRoot.load() so that it properly handles relative URLs in a way that doesn't break subsequent API calls

Description of the change

== Implementation ==

The ServiceRoot.load() API takes a url as a parameter. In the case where the URL is relative, a URI object was being constructed and assigned to the url. However, this conflicted with the case where a full url was passed in as a string, and also downstream processing which expects the url to be a string. So the simple fix is simply to stringify the constructed URI object when a relative URL is passed in.

== Tests ==

Add some extra checks to entries.txt

== Lint ==

Did some lint cleanup to make everything happy.

To post a comment you must log in.
Revision history for this message
Curtis Hovey (sinzui) wrote :

Thank you for the fix and the de-linting.

review: Approve (code)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches