[python-nextgen] Better oneOf, anyOf support (#14743)

* better oneof, anyof support

* improve anyof support

* fix deprecation warning

* fix anyof, add tests

* add nullable support, add test
This commit is contained in:
William Cheng
2023-02-19 17:16:15 +08:00
committed by GitHub
parent 0891b6056f
commit 1bd3ce7ce2
34 changed files with 1185 additions and 46 deletions

View File

@@ -38,11 +38,11 @@ class RESTResponse(io.IOBase):
def getheaders(self):
"""Returns a dictionary of the response headers."""
return self.urllib3_response.getheaders()
return self.urllib3_response.headers
def getheader(self, name, default=None):
"""Returns a given response header."""
return self.urllib3_response.getheader(name, default)
return self.urllib3_response.headers.get(name, default)
class RESTClientObject(object):