Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update python-base #1161

Merged
merged 1 commit into from
May 26, 2020
Merged

update python-base #1161

merged 1 commit into from
May 26, 2020

Conversation

zshihang
Copy link
Contributor

@zshihang zshihang commented May 5, 2020

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label May 5, 2020
@k8s-ci-robot
Copy link
Contributor

Welcome @zshihang!

It looks like this is your first PR to kubernetes-client/python 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes-client/python has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot k8s-ci-robot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label May 5, 2020
@zshihang
Copy link
Contributor Author

zshihang commented May 5, 2020

/assign @yliaog

@palnabarun
Copy link
Member

I don't know if we should put a hold on updating the base client until #1141 gets merged.

What do you think @roycaihw ?

@roycaihw
Copy link
Member

It looks like the tests are failing https://travis-ci.org/github/kubernetes-client/python/jobs/683532228:

__ ERROR at setup of TestUtils.test_create_apiservice_from_yaml_with_conflict __
cls = <class 'kubernetes.e2e_test.test_utils.TestUtils'>
    @classmethod
    def setUpClass(cls):
        cls.config = base.get_e2e_configuration()
        cls.path_prefix = "kubernetes/e2e_test/test_yaml/"
        cls.test_namespace = "e2e-test-utils"
        k8s_client = client.api_client.ApiClient(configuration=cls.config)
        core_v1 = client.CoreV1Api(api_client=k8s_client)
        body = client.V1Namespace(metadata=client.V1ObjectMeta(name=cls.test_namespace))
>       core_v1.create_namespace(body=body)
kubernetes/e2e_test/test_utils.py:33: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
kubernetes/client/api/core_v1_api.py:5369: in create_namespace
    (data) = self.create_namespace_with_http_info(body, **kwargs)  # noqa: E501
kubernetes/client/api/core_v1_api.py:5453: in create_namespace_with_http_info
    collection_formats=collection_formats)
kubernetes/client/api_client.py:345: in call_api
    _preload_content, _request_timeout)
kubernetes/client/api_client.py:162: in __call_api
    self.update_params_for_auth(header_params, query_params, auth_settings)
kubernetes/client/api_client.py:519: in update_params_for_auth
    auth_setting = self.configuration.auth_settings().get(auth)
kubernetes/client/configuration.py:220: in auth_settings
    'value': self.get_api_key_with_prefix('authorization')
kubernetes/config/incluster_config.py:90: in wrapped
    in_cluster_config._read_token_file()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
self = <kubernetes.config.incluster_config.InClusterConfigLoader object at 0x7efe97d26250>
    def _read_token_file(self):
>       with open(self._token_filename) as f:
E       IOError: [Errno 2] No such file or directory: '/tmp/tmpbY7GUX'
kubernetes/config/incluster_config.py:97: IOError
______ ERROR at setup of TestUtils.test_create_apps_deployment_from_yaml _______

Travis ci is having trouble reporting the result back to github, but it's still visible in travis. We need to make sure the tests are green before merging

@zshihang
Copy link
Contributor Author

i have run locally and it is passing.

python -m unittest discover
...
Running test against : https://192.168.9.2:8443
...
Ran 1617 tests in 37.708s

OK

i'll rebase and try again.

@roycaihw
Copy link
Member

I think the failing ones are e2e tests, which aren't covered by the unittest

@zshihang
Copy link
Contributor Author

@roycaihw
Copy link
Member

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label May 26, 2020
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: roycaihw, zshihang

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 26, 2020
@k8s-ci-robot k8s-ci-robot merged commit b6e4ae8 into kubernetes-client:master May 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

periodically reload InClusterConfig token
5 participants