uv/crates/gourgeist/src
Jo 2016ec4cfe
Use full python version in `pyvenv.cfg` (#1979)
## Summary

For a venv created by `virtualenv`, the `pyvenv.cfg` file specifies the
full version string in the `version_info` field:

```
home = /Users/x/.rye/py/cpython@3.12.1/install/bin
implementation = CPython
version_info = 3.12.1.final.0
virtualenv = 20.25.0
include-system-site-packages = false
base-prefix = /Users/x/.rye/py/cpython@3.12.1/install
base-exec-prefix = /Users/x/.rye/py/cpython@3.12.1/install
base-executable = /Users/x/.rye/py/cpython@3.12.1/install/bin/python3
```

The relevant code can be found here: 

4ca8a20c17/src/virtualenv/create/creator.py (L167)

This PR changes `pyvenv.cfg` created by uv for better compatibility with
`virtualenv`.

## Test Plan

```sh
uv venv
cat .venv/pyvenv.cfg
```
2024-02-26 09:52:17 -05:00
..
activator Add support for `venv --prompt` (#1570) 2024-02-20 00:43:20 +05:30
_virtualenv.py Avoid import contextlib in `_virtualenv` (#1406) 2024-02-15 20:23:05 -05:00
activate Copy over `gourgeist` crate (#61) 2023-10-08 14:37:09 -04:00
bare.rs Use full python version in `pyvenv.cfg` (#1979) 2024-02-26 09:52:17 -05:00
lib.rs Clippy pedantic (#1963) 2024-02-25 14:04:05 -05:00
main.rs Improve interpreter discovery logging (#1909) 2024-02-23 18:43:46 +00:00