You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This PR fixed kubernetes/kubernetes#84503 changed the behaviour of kubectl config unset slightly that if no users left in kubeconfig after user run kubectl config unset users., the value of users field in kubeconfig would be set to null rather than [].
since users set to null, kubernetes.config.kube_config.load_kube_config() can't work, this pr set a default empty list to users
It may take a couple minutes for the CLA signature to be fully registered; after that, please reply here with a new comment and we'll verify. Thanks.
If you've already signed a CLA, it's possible we don't have your GitHub username or you're using a different email address. Check your existing CLA data and verify that your email is set on your git commits.
If you have done the above and are still having issues with the CLA being reported as unsigned, please log a ticket with the Linux Foundation Helpdesk: https://support.linuxfoundation.org/
Should you encounter any issues with the Linux Foundation Helpdesk, send a message to the backup e-mail support address at: login-issues@jira.linuxfoundation.org
Details
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.
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 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!
Could you add a unit test for this behavior? Thanks
since users set to None, load_config() run like the following error:
.....................config/kube_config_test.py:1345: DeprecationWarning: Please use assertEqual instead.
self.assertEquals(actual._config_persister.__name__, "save_changes")
....................................EEE...
======================================================================
ERROR: test_list_kube_config_contexts (__main__.TestKubeConfigMerger)
----------------------------------------------------------------------
Traceback (most recent call last):
File "config/kube_config_test.py", line 1545, in test_list_kube_config_contexts
contexts, active_context = list_kube_config_contexts(
File "/home/ac/Project/PythonWorksPaces/python-base/config/kube_config.py", line 714, in list_kube_config_contexts
loader = _get_kube_config_loader_for_yaml_file(config_file)
File "/home/ac/Project/PythonWorksPaces/python-base/config/kube_config.py", line 694, in _get_kube_config_loader_for_yaml_file
kcfg = KubeConfigMerger(filename)
File "/home/ac/Project/PythonWorksPaces/python-base/config/kube_config.py", line 650, in __init__
self.load_config(path)
File "/home/ac/Project/PythonWorksPaces/python-base/config/kube_config.py", line 667, in load_config
self._merge(item, config.get(item, []), path)
File "/home/ac/Project/PythonWorksPaces/python-base/config/kube_config.py", line 671, in _merge
for new_item in add_cfg:
TypeError: 'NoneType' object is not iterable
k8s-ci-robot
added
size/M
Denotes a PR that changes 30-99 lines, ignoring generated files.
and removed
size/XS
Denotes a PR that changes 0-9 lines, ignoring generated files.
labels
Jun 23, 2020
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.
k8s-ci-robot
added
size/S
Denotes a PR that changes 10-29 lines, ignoring generated files.
and removed
size/M
Denotes a PR that changes 30-99 lines, ignoring generated files.
labels
Jun 25, 2020
k8s-ci-robot
added
lgtm
Indicates that a PR is ready to be merged.
and removed
do-not-merge/hold
Indicates that a PR should not merge because someone has issued a /hold command.
labels
Jun 25, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
approvedIndicates a PR has been approved by an approver from all required OWNERS files.cncf-cla: yesIndicates the PR's author has signed the CNCF CLA.lgtmIndicates that a PR is ready to be merged.size/SDenotes a PR that changes 10-29 lines, ignoring generated files.
4 participants
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR fixed
kubernetes/kubernetes#84503 changed the behaviour of kubectl config unset slightly that if no users left in kubeconfig after user run kubectl config unset users., the value of users field in kubeconfig would be set to null rather than [].
since users set to null, kubernetes.config.kube_config.load_kube_config() can't work, this pr set a default empty list to users
Which issue(s) this PR fixes:
Try to fixes
#183
#181