dstack icon indicating copy to clipboard operation
dstack copied to clipboard

[Bug]: Unexpected error if system Python version is unknown

Open jvstme opened this issue 1 year ago • 0 comments

dstack version

master

Steps to reproduce

  1. Install dstack and run dstack server on a Python version not listed in PythonVersion
  2. Run a job without specifying python or image in config file
    $ cat hello.yml
    type: task
    
    commands:
      - python -c 'print("Hello dstack!")'
    
    $ dstack run . -f hello.yml
    

Expected result

The user is notified that they should specify the Python version in config file, as their system Python version is not supported

Actual result

CLI:

Unexpected dstack server error

Server logs:

ValueError: '3.12' is not a valid PythonVersion

jvstme avatar Mar 19 '24 12:03 jvstme