Sure, here’s the traceback:
ERROR:root:
Traceback (most recent call last):
File "C:\Tools\Anaconda3\lib\site-packages\dask_kubernetes\operator\kubecluster\kubecluster.py", line 284, in _create_cluster
await custom_objects_api.create_namespaced_custom_object(
File "C:\Tools\Anaconda3\lib\site-packages\kubernetes_asyncio\client\api_client.py", line 192, in __call_api
raise e
File "C:\Tools\Anaconda3\lib\site-packages\kubernetes_asyncio\client\api_client.py", line 185, in __call_api
response_data = await self.request(
File "C:\Tools\Anaconda3\lib\site-packages\kubernetes_asyncio\client\rest.py", line 230, in POST
return (await self.request("POST", url,
File "C:\Tools\Anaconda3\lib\site-packages\kubernetes_asyncio\client\rest.py", line 187, in request
raise ApiException(http_resp=r)
kubernetes_asyncio.client.exceptions.ApiException: (401)
Reason: Unauthorized
HTTP response headers: <CIMultiDictProxy('Audit-Id': '9b4da9c5-49ba-48e5-bc35-4ba247a991b9', 'Cache-Control': 'no-cache, private', 'Content-Type': 'application/json', 'Date': 'Tue, 14 Mar 2023 17:03:06 GMT', 'Content-L
ength': '129')>
HTTP response body: {"kind":"Status","apiVersion":"v1","metadata":{},"status":"Failure","message":"Unauthorized","reason":"Unauthorized","code":401}
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "C:\Projects\Lennar\dask\test.py", line 3, in <module>
cluster = KubeCluster(name='testcluster',namespace='prefect-dev')
File "C:\Tools\Anaconda3\lib\site-packages\dask_kubernetes\operator\kubecluster\kubecluster.py", line 229, in __init__
self.sync(self._start)
File "C:\Tools\Anaconda3\lib\site-packages\distributed\utils.py", line 338, in sync
return sync(
File "C:\Tools\Anaconda3\lib\site-packages\distributed\utils.py", line 405, in sync
raise exc.with_traceback(tb)
File "C:\Tools\Anaconda3\lib\site-packages\distributed\utils.py", line 378, in f
result = yield future
File "C:\Tools\Anaconda3\lib\site-packages\tornado\gen.py", line 762, in run
value = future.result()
File "C:\Tools\Anaconda3\lib\site-packages\dask_kubernetes\operator\kubecluster\kubecluster.py", line 252, in _start
await self._create_cluster()
File "C:\Tools\Anaconda3\lib\site-packages\dask_kubernetes\operator\kubecluster\kubecluster.py", line 292, in _create_cluster
raise RuntimeError(
RuntimeError: Failed to create DaskCluster resource. Are the Dask Custom Resource Definitions installed? https://kubernetes.dask.org/en/latest/operator.html#installing-the-operator
ERROR:root:
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "C:\Tools\Anaconda3\lib\asyncio\runners.py", line 44, in run
return loop.run_until_complete(main)
File "C:\Tools\Anaconda3\lib\asyncio\base_events.py", line 647, in run_until_complete
return future.result()
File "C:\Tools\Anaconda3\lib\site-packages\dask_kubernetes\operator\kubecluster\kubecluster.py", line 909, in _reap_clusters
cluster.close(timeout=10)
File "C:\Tools\Anaconda3\lib\site-packages\dask_kubernetes\operator\kubecluster\kubecluster.py", line 571, in close
return self.sync(self._close, timeout=timeout)
File "C:\Tools\Anaconda3\lib\site-packages\distributed\utils.py", line 338, in sync
return sync(
File "C:\Tools\Anaconda3\lib\site-packages\distributed\utils.py", line 405, in sync
raise exc.with_traceback(tb)
File "C:\Tools\Anaconda3\lib\site-packages\distributed\utils.py", line 378, in f
result = yield future
File "C:\Tools\Anaconda3\lib\site-packages\tornado\gen.py", line 762, in run
value = future.result()
File "C:\Tools\Anaconda3\lib\site-packages\dask_kubernetes\operator\kubecluster\kubecluster.py", line 579, in _close
await custom_objects_api.delete_namespaced_custom_object(
File "C:\Tools\Anaconda3\lib\site-packages\kubernetes_asyncio\client\api_client.py", line 185, in __call_api
response_data = await self.request(
File "C:\Tools\Anaconda3\lib\site-packages\kubernetes_asyncio\client\rest.py", line 220, in DELETE
return (await self.request("DELETE", url,
File "C:\Tools\Anaconda3\lib\site-packages\kubernetes_asyncio\client\rest.py", line 177, in request
r = await self.pool_manager.request(**args)
File "C:\Tools\Anaconda3\lib\site-packages\aiohttp\client.py", line 536, in _request
conn = await self._connector.connect(
File "C:\Tools\Anaconda3\lib\site-packages\aiohttp\connector.py", line 540, in connect
proto = await self._create_connection(req, traces, timeout)
File "C:\Tools\Anaconda3\lib\site-packages\aiohttp\connector.py", line 901, in _create_connection
_, proto = await self._create_direct_connection(req, traces, timeout)
File "C:\Tools\Anaconda3\lib\site-packages\aiohttp\connector.py", line 1152, in _create_direct_connection
hosts = await asyncio.shield(host_resolved)
File "C:\Tools\Anaconda3\lib\site-packages\aiohttp\connector.py", line 874, in _resolve_host
addrs = await self._resolver.resolve(host, port, family=self._family)
File "C:\Tools\Anaconda3\lib\site-packages\aiohttp\resolver.py", line 33, in resolve
infos = await self._loop.getaddrinfo(
File "C:\Tools\Anaconda3\lib\asyncio\base_events.py", line 861, in getaddrinfo
return await self.run_in_executor(
File "C:\Tools\Anaconda3\lib\asyncio\base_events.py", line 819, in run_in_executor
executor.submit(func, *args), loop=self)
File "C:\Tools\Anaconda3\lib\concurrent\futures\thread.py", line 167, in submit
raise RuntimeError('cannot schedule new futures after shutdown')
RuntimeError: cannot schedule new futures after shutdown