Thanks @guillaumeeb
When I change:
dask-gateway:
gateway:
prefix: /services/dask-gateway
with:
dask-gateway:
gateway:
prefix: /services/dask-gateway-other
I run:
from dask_gateway import Gateway
gateway = Gateway()
clusters = gateway.list_clusters()
print(clusters)
and I get:
---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
Input In [2], in <cell line: 1>()
----> 1 clusters = gateway.list_clusters()
2 print(clusters)
File /srv/conda/envs/notebook/lib/python3.9/site-packages/dask_gateway/client.py:456, in Gateway.list_clusters(self, status, **kwargs)
442 def list_clusters(self, status=None, **kwargs):
443 """List clusters for this user.
444
445 Parameters
(...)
454 clusters : list of ClusterReport
455 """
--> 456 return self.sync(self._clusters, status=status, **kwargs)
File /srv/conda/envs/notebook/lib/python3.9/site-packages/dask_gateway/client.py:344, in Gateway.sync(self, func, *args, **kwargs)
340 future = asyncio.run_coroutine_threadsafe(
341 func(*args, **kwargs), self.loop.asyncio_loop
342 )
343 try:
--> 344 return future.result()
345 except BaseException:
346 future.cancel()
File /srv/conda/envs/notebook/lib/python3.9/concurrent/futures/_base.py:446, in Future.result(self, timeout)
444 raise CancelledError()
445 elif self._state == FINISHED:
--> 446 return self.__get_result()
447 else:
448 raise TimeoutError()
File /srv/conda/envs/notebook/lib/python3.9/concurrent/futures/_base.py:391, in Future.__get_result(self)
389 if self._exception:
390 try:
--> 391 raise self._exception
392 finally:
393 # Break a reference cycle with the exception in self._exception
394 self = None
File /srv/conda/envs/notebook/lib/python3.9/site-packages/dask_gateway/client.py:435, in Gateway._clusters(self, status)
432 query = ""
434 url = f"{self.address}/api/v1/clusters/{query}"
--> 435 resp = await self._request("GET", url)
436 data = await resp.json()
437 return [
438 ClusterReport._from_json(self._public_address, self.proxy_address, r)
439 for r in data.values()
440 ]
File /srv/conda/envs/notebook/lib/python3.9/site-packages/dask_gateway/client.py:414, in Gateway._request(self, method, url, json)
411 msg = await resp.text()
413 if resp.status in {404, 422}:
--> 414 raise ValueError(msg)
415 elif resp.status == 409:
416 raise GatewayClusterError(msg)
ValueError: 404 page not found
Switching back to:
dask-gateway:
gateway:
prefix: /services/dask-gateway
Resolves the 404
error above.
Hopefully that’s what you mean with:
Do you think you could try to change the genereated services names on one of the two clusters?
Any thoughts?
Best regards,
Sebastian