Skip to content

Commit

Permalink
PR #756 amendments
Browse files Browse the repository at this point in the history
- better comment for race condition fix
- removed unused imports

#756
  • Loading branch information
xoen committed Oct 3, 2019
1 parent 2f01759 commit 7f14ac7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 3 additions & 1 deletion controlpanel/api/kubernetes.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ def get_config():

config = kubernetes.client.Configuration()

# The deepcopy is to avoid a race conditions on the credentials keys
# A deepcopy of the configuration is used to avoid a race condition
# caused by subsequent calls to Configuration() reusing a singleton
# datastructure
#
# See: https://github.com/kubernetes-client/python/issues/932
config.api_key_prefix = deepcopy(config.api_key_prefix)
Expand Down
2 changes: 0 additions & 2 deletions controlpanel/kubeapi/views.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
from functools import wraps
from urllib.parse import urljoin

from django.conf import settings
from django.core import exceptions
from django.views.decorators.csrf import csrf_exempt
from djproxy.views import HttpProxy
Expand Down

0 comments on commit 7f14ac7

Please sign in to comment.