Skip to content

Consider uv over venv + pip to circumvent sys.path.append(). #277

Description

@teddythepooh

In your ETL (https://github.com/AH-Datalytics/rtci/tree/main/pipeline), you have sys.path.append() everywhere to import from utils/.

I highly recommend foregoing requirements.txt in favor of pyproject.toml, ideally automated with uv: an extremely fast alternative to venv + pip. This way, you can import your utils functions anywhere without sys.path.append().

Here is an example:

Notice how smoothly I am able to import FBI from ./src/fbi_api/core.py onto ./tests/conftest.py.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions