Skip to content

Commit

Permalink
Make exception handling compatible with Python < 3.11
Browse files Browse the repository at this point in the history
  • Loading branch information
mfisher87 committed Apr 26, 2024
1 parent 293fba0 commit fbbd8d9
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions parsl/providers/kubernetes/kube.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,9 @@ def __init__(self,
# Based on: https://github.com/kubernetes-client/python/issues/1005
try:
config.load_incluster_config()
except Exception as incluster_config_exception:
raise ExceptionGroup(
"Encountered errors loading kubernetes cluster configuration",
[kube_config_exception, incluster_config_exception],
except config.config_exception.ConfigException:
raise config.config_exception.ConfigException(
"Failed to load both kube-config file and in-cluster configuration."
)


Expand Down

0 comments on commit fbbd8d9

Please sign in to comment.