VisionSystemsInc / VisionSystemsInc/vsi_common

Local editable packages don't have dependency resolution

Open
#151 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement just
Dominant language
Shell
Stars
8
Forks
9
Avg merge
36m
Merged PRs (30d)
1

Description

Pipenv doesn't respect the dependencies of local editable packages.

One such solution is to generate a setup.py file that will configure dynamic dependencies.:

This can solve a few problems at once.

  1. The dependencies of local editable packages can be scanned and added to this pipenv_patch package. This will remove the duplicated dependencies in the Pipfile.
    1. Maybe this pipenv_patch can even parse the Pipfile and get the list of editable packages (no recursion search needed for this. Just get the list from reading the Pipfile since dependencies can't be editable unless they are listed there)
    2. This patch will read the setup.py files, and get the list of dependencies from them, and call them its own.
  2. (optional) We can check an environment variable and dynamically add other dependencies based on that. This is to solve pipenv issue 3167. Since the Pipfileallows you to add other sections that are ignored, you could for example have
[foo-packages]
ipykernel = "*"

And the foo packages are parsed only if an environment variable is set to foo. There could also be a [not-foo-packages] too. This will work well for the tensorflow vs tensorflow-gpu scenario. But this whole optional idea might not pan out either.

@scott-vsi

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by examining how the repository currently handles the Pipfile and local editable packages; the issue proposes reading editable entries from the Pipfile and dependencies from each package's setup.py. Define the dependency-resolution behavior before implementing it, and consider the optional environment-variable package sections separately. Done means local editable dependencies are discovered without duplicated Pipfile entries, with coverage for the supported cases.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
build-system
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.