Skip to content

Commit 1ab119d

Browse files
authored
Rename async to async_req for compatibility with python3 and kubernetes 7 (#197)
* Rename async to async_req for python3 and kubernetes 7 compatibility * Update requirements * Update versions * update tests * update tox for 3.9 * fix py3 test issue
1 parent 5f1d83d commit 1ab119d

36 files changed

+5163
-5158
lines changed

.travis.yml

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,18 +9,14 @@ python:
99
- '3.5'
1010
env:
1111
- TEST_SUITE=test OPENSHIFT_VERSION=latest
12+
- TEST_SUITE=test OPENSHIFT_VERSION=3.9
1213
- TEST_SUITE=test OPENSHIFT_VERSION=3.7
13-
- TEST_SUITE=test OPENSHIFT_VERSION=3.6
14-
- TEST_SUITE=test OPENSHIFT_VERSION=1.5
15-
- TEST_SUITE=generate
1614
script: tox
1715
install:
1816
- pip install tox-travis coveralls
1917
after_success:
2018
- coveralls
2119
jobs:
22-
allow_failures:
23-
- env: TEST_SUITE=generate
2420
include:
2521
- stage: lint
2622
python: '2.7'
@@ -53,5 +49,7 @@ jobs:
5349
stages:
5450
- lint
5551
- test
56-
- deploy
57-
- test-deploy
52+
- name: deploy
53+
if: (tag is present) and (type = push)
54+
- name: test-deploy
55+
if: (tag is present) and (type = push)

openshift/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ OpenShift provides builds, application lifecycle, image content management, and
44
This Python package is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:
55

66
- API version: latest
7-
- Package version: 0.6.2
7+
- Package version: 0.7.0
88
- Build package: io.swagger.codegen.languages.PythonClientCodegen
99

1010
## Requirements.

openshift/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,5 @@
1818

1919
# Do not edit these constants. They will be updated automatically
2020
# by scripts/update-client.sh.
21-
__version__ = "0.6.2"
22-
__k8s_client_version__ = "6.0.0"
21+
__version__ = "0.7.0"
22+
__k8s_client_version__ = "7.0.0"

openshift/client/apis/apps_openshift_io_api.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -39,17 +39,17 @@ def get_api_group(self, **kwargs):
3939
"""
4040
get information of a group
4141
This method makes a synchronous HTTP request by default. To make an
42-
asynchronous HTTP request, please pass async=True
43-
>>> thread = api.get_api_group(async=True)
42+
asynchronous HTTP request, please pass async_req=True
43+
>>> thread = api.get_api_group(async_req=True)
4444
>>> result = thread.get()
4545
46-
:param async bool
46+
:param async_req bool
4747
:return: V1APIGroup
4848
If the method is called asynchronously,
4949
returns the request thread.
5050
"""
5151
kwargs['_return_http_data_only'] = True
52-
if kwargs.get('async'):
52+
if kwargs.get('async_req'):
5353
return self.get_api_group_with_http_info(**kwargs)
5454
else:
5555
(data) = self.get_api_group_with_http_info(**kwargs)
@@ -59,18 +59,18 @@ def get_api_group_with_http_info(self, **kwargs):
5959
"""
6060
get information of a group
6161
This method makes a synchronous HTTP request by default. To make an
62-
asynchronous HTTP request, please pass async=True
63-
>>> thread = api.get_api_group_with_http_info(async=True)
62+
asynchronous HTTP request, please pass async_req=True
63+
>>> thread = api.get_api_group_with_http_info(async_req=True)
6464
>>> result = thread.get()
6565
66-
:param async bool
66+
:param async_req bool
6767
:return: V1APIGroup
6868
If the method is called asynchronously,
6969
returns the request thread.
7070
"""
7171

7272
all_params = []
73-
all_params.append('async')
73+
all_params.append('async_req')
7474
all_params.append('_return_http_data_only')
7575
all_params.append('_preload_content')
7676
all_params.append('_request_timeout')
@@ -117,7 +117,7 @@ def get_api_group_with_http_info(self, **kwargs):
117117
files=local_var_files,
118118
response_type='V1APIGroup',
119119
auth_settings=auth_settings,
120-
async=params.get('async'),
120+
async_req=params.get('async_req'),
121121
_return_http_data_only=params.get('_return_http_data_only'),
122122
_preload_content=params.get('_preload_content', True),
123123
_request_timeout=params.get('_request_timeout'),

openshift/client/apis/apps_openshift_io_v1_api.py

Lines changed: 171 additions & 171 deletions
Large diffs are not rendered by default.

openshift/client/apis/authorization_openshift_io_api.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -39,17 +39,17 @@ def get_api_group(self, **kwargs):
3939
"""
4040
get information of a group
4141
This method makes a synchronous HTTP request by default. To make an
42-
asynchronous HTTP request, please pass async=True
43-
>>> thread = api.get_api_group(async=True)
42+
asynchronous HTTP request, please pass async_req=True
43+
>>> thread = api.get_api_group(async_req=True)
4444
>>> result = thread.get()
4545
46-
:param async bool
46+
:param async_req bool
4747
:return: V1APIGroup
4848
If the method is called asynchronously,
4949
returns the request thread.
5050
"""
5151
kwargs['_return_http_data_only'] = True
52-
if kwargs.get('async'):
52+
if kwargs.get('async_req'):
5353
return self.get_api_group_with_http_info(**kwargs)
5454
else:
5555
(data) = self.get_api_group_with_http_info(**kwargs)
@@ -59,18 +59,18 @@ def get_api_group_with_http_info(self, **kwargs):
5959
"""
6060
get information of a group
6161
This method makes a synchronous HTTP request by default. To make an
62-
asynchronous HTTP request, please pass async=True
63-
>>> thread = api.get_api_group_with_http_info(async=True)
62+
asynchronous HTTP request, please pass async_req=True
63+
>>> thread = api.get_api_group_with_http_info(async_req=True)
6464
>>> result = thread.get()
6565
66-
:param async bool
66+
:param async_req bool
6767
:return: V1APIGroup
6868
If the method is called asynchronously,
6969
returns the request thread.
7070
"""
7171

7272
all_params = []
73-
all_params.append('async')
73+
all_params.append('async_req')
7474
all_params.append('_return_http_data_only')
7575
all_params.append('_preload_content')
7676
all_params.append('_request_timeout')
@@ -117,7 +117,7 @@ def get_api_group_with_http_info(self, **kwargs):
117117
files=local_var_files,
118118
response_type='V1APIGroup',
119119
auth_settings=auth_settings,
120-
async=params.get('async'),
120+
async_req=params.get('async_req'),
121121
_return_http_data_only=params.get('_return_http_data_only'),
122122
_preload_content=params.get('_preload_content', True),
123123
_request_timeout=params.get('_request_timeout'),

0 commit comments

Comments
 (0)