Skip to content
This repository has been archived by the owner on Apr 4, 2022. It is now read-only.

Bug in URL building introduced in v2.2.2 #138

Open
mfulgo opened this issue Aug 18, 2017 · 2 comments
Open

Bug in URL building introduced in v2.2.2 #138

mfulgo opened this issue Aug 18, 2017 · 2 comments

Comments

@mfulgo
Copy link

mfulgo commented Aug 18, 2017

There was a change introduced after versions 2.2.1 that breaks making a PUT request - the path part of the request is omitted. (This may also be the case for other types of requests. The issue also affects v2.3.0.)

I'm still working out the details of where exactly the bug is, but I wanted to give you a heads-up that this is coming.

The result of Http L335 changed between the two versions:

val urlToFetch: URL = new URL(urlBuilder(this))

In version 2.2.1, this would return a URL including the path. In 2.2.2, it just returns the protocol, host, and port.

@mfulgo
Copy link
Author

mfulgo commented Aug 18, 2017

@hoffrocket - I figured it out, and it's not really a bug so much as a versioning and documentation issue. In 131b20e, you added two new "put" methods to the public API. Since this was non-breaking, new functionality, it probably deserved a minor version bump.

Unfortunately, our code had an implicit conversion defined for a put method that took a String that was the path, not the body. Since the two functions had the same signature, the implicit was no longer used but the code still compiled... Alas.

Feel free to close this as you see fit.

@mfulgo
Copy link
Author

mfulgo commented Aug 18, 2017

On a related note, the two methods probably should have been named putData for consistency with postData.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant