splunk/splunk-sdk-python — Issue #17: HttpLib#request has strange argument names
Author: Ansman
Created: 2011-11-08 18:36:30+00:00
State: open

If you look at how `Context#request` calls `HttpLib#request` it looks like this:

return self.http.request(
self.url(path), {
'method': message.get("method", "GET"),
'headers': message.get("headers", []) + self._headers(),
'body': message.get("body", "")})

But if you look at the signature for `HttpLib#request`:

def request(self, url, headers=None, **kwargs):

And in turn when that calls the `Handler#request` the signature is:

def request(url, message, **kwargs):

Why is the second argument of `HttpLib#request` named `headers` when it's clearly the `message` argument later?