Running:
make test tests=src/toil/test/sort/sortTest.py::SortTest::testSort
or
python -m pytest src/toil/test/sort/sortTest.py::SortTest::testSort -vv
fails during import of src/toil/test/conftest.py because src/toil/test/__init__.py calls _is_kubernetes_installed_and_configured(), which calls kubernetes.config.load_kube_config().
Error:
E oauthlib.oauth2.rfc6749.errors.CustomOAuth2Error: ("invalid_token" E error_description="token not found" E )
I likely have a staled/revoked OIDC token in ~/.kube/config (kubectl/kubeconfig present, but creds not valid).
Expected behavior is that this is treated as “kubernetes not usable” and Kubernetes tests are skipped, instead of failing pytest import.
┆Issue is synchronized with this Jira Story
┆Issue Number: TOIL-1829
Running:
make test tests=src/toil/test/sort/sortTest.py::SortTest::testSortor
python -m pytest src/toil/test/sort/sortTest.py::SortTest::testSort -vvfails during import of
src/toil/test/conftest.pybecausesrc/toil/test/__init__.pycalls_is_kubernetes_installed_and_configured(),which callskubernetes.config.load_kube_config().Error:
E oauthlib.oauth2.rfc6749.errors.CustomOAuth2Error: ("invalid_token" E error_description="token not found" E )I likely have a staled/revoked OIDC token in
~/.kube/config(kubectl/kubeconfig present, but creds not valid).Expected behavior is that this is treated as “kubernetes not usable” and Kubernetes tests are skipped, instead of failing pytest import.
┆Issue is synchronized with this Jira Story
┆Issue Number: TOIL-1829