Skip to content

Standardise poetry virtual env config

Tan Le requested to merge standardise-poetry-venv-config into main

What does this merge request do and why?

Standardise poetry virtual env config

  • Create the virtualenv inside the project’s root directory.
  • All needed files are copied into it instead of symlinked.

How to set up and validate locally

  1. Check out to this merge request's branch.
  2. Verify that the config is setup correctly.
    $ poetry config --list -vvv
    Loading configuration file /Users/tanle/Library/Application Support/pypoetry/config.toml
    Loading configuration file /Users/tanle/code/gitlab/ai-assist-api/poetry.toml
    cache-dir = "/Users/tanle/Library/Caches/pypoetry"
    --snip--
    virtualenvs.create = true
    virtualenvs.in-project = true
    virtualenvs.options.always-copy = true
    --snip--
  3. Recreatd the current virtual env.
    $ rm -rf .venv
    $ poetry install
    Creating virtualenv ai-gateway in /Users/tanle/code/gitlab/ai-assist-api/.venv
    --snip--

Merge request checklist

  • Tests added for new functionality. If not, please raise an issue to follow up.
  • Documentation added/updated, if needed.
Edited by Tan Le

Merge request reports

Loading