databricks-cli/libs/python
Gleb Kanterov 44902fa350
Make `pydabs/venv_path` optional (#1687)
## Changes
Make `pydabs/venv_path` optional. When not specified, CLI detects the
Python interpreter using `python.DetectExecutable`, the same way as for
`artifacts`. `python.DetectExecutable` works correctly if a virtual
environment is activated or `python3` is available on PATH through other
means.

Extract the venv detection code from PyDABs into `libs/python/detect`.
This code will be used when we implement the `python/venv_path` section
in `databricks.yml`.

## Tests
Unit tests and manually

---------

Co-authored-by: Pieter Noordhuis <pcnoordhuis@gmail.com>
2024-08-20 13:26:57 +00:00
..
testdata Added `python.DetectInterpreters` and other utils (#805) 2023-10-03 10:47:09 +00:00
detect.go Make `pydabs/venv_path` optional (#1687) 2024-08-20 13:26:57 +00:00
detect_test.go Make `pydabs/venv_path` optional (#1687) 2024-08-20 13:26:57 +00:00
detect_unix_test.go Added `python.DetectInterpreters` and other utils (#805) 2023-10-03 10:47:09 +00:00
detect_win_test.go Added `python.DetectInterpreters` and other utils (#805) 2023-10-03 10:47:09 +00:00
interpreters.go Added `python.DetectInterpreters` and other utils (#805) 2023-10-03 10:47:09 +00:00
interpreters_unix_test.go Added `python.DetectInterpreters` and other utils (#805) 2023-10-03 10:47:09 +00:00
interpreters_win_test.go Added `python.DetectInterpreters` and other utils (#805) 2023-10-03 10:47:09 +00:00
utils.go Added `python.DetectInterpreters` and other utils (#805) 2023-10-03 10:47:09 +00:00
utils_test.go Added `python.DetectInterpreters` and other utils (#805) 2023-10-03 10:47:09 +00:00
venv.go Added `python.DetectInterpreters` and other utils (#805) 2023-10-03 10:47:09 +00:00
venv_test.go Added `python.DetectInterpreters` and other utils (#805) 2023-10-03 10:47:09 +00:00