dstack icon indicating copy to clipboard operation
dstack copied to clipboard

[Bug]: `dstack offer` shows all backend regions for each gpu

Open r4victor opened this issue 4 months ago • 1 comments

Steps to reproduce

  1. Run dstack offer --group-by gpu,backend.
  2. Observe that it shows all REGIONS that backend has for each GPU even if this GPU only available for certain regions.
✗ dstack offer --group-by gpu,backend
 Project      main                           
 Resources    cpu=2.. mem=8GB.. disk=100GB.. 
 Spot policy  auto                           
 Max price    -                              
 Reservation  -                              
 Group by     gpu, backend                   

 #   GPU             SPOT    $/GPU   BACKEND         REGIONS                       
 1   A2000:6GB:1     spot,   0.06.…  runpod          40 regions                    
                     on-de…                                                        
 2   RTX3070:8GB:1…  spot,   0.07.…  runpod          40 regions                    
                     on-de…                                                        
 3   RTX3080:10GB:…  spot,   0.09.…  runpod          40 regions

Actual behaviour

There is no per-gpu region list, only the per-backend one:

https://github.com/dstackai/dstack/blob/f76cda6880a8885cb9e62afe8204a1f8a6fb5621/src/dstack/_internal/server/services/gpus.py#L55-L58

Expected behaviour

Only regions that have that GPU and showed in REGIONS. This is especially relevant for accelerator types that are available in very limited number of regions (e.g. TPUs).

dstack version

master

Server logs


Additional information

No response

r4victor avatar Aug 21 '25 06:08 r4victor