'Pipenv install current directory without modifying Pipfile

I'm working on a project that has many users and contributors. But it isn't very active and hasn't been updated in a while. The development environment setup instructions say to:

  1. git clone the repository
  2. Run pip install . inside the directory
  3. Add the compiled binary to my PATH

I think pipenv is the way to go nowadays, so I converted the requirements.txt to a Pipfile and ran pipenv install . instead. This had some unexpected side effects:

  1. It added the current directory to the list of packages in the Pipfile.
  2. It added the current directory and all of its sub-dependencies to Pipfile.lock.

To help clarify, this is what I mean by 1:

$ git diff
diff --git a/Pipfile b/Pipfile
index 47952a2..5fd793e 100644
--- a/Pipfile
+++ b/Pipfile
@@ -17,6 +17,7 @@ boto3 = "*"
 click = "*"
 pytest = "*"
 requests = "*"
+mypackage = {path = "."}

I read here that it should only add the sub-dependencies to Pipfile.lock if I add -e to the pipenv install command, but appears to do so regardless. I think that's a bug, but that's beside the point. The point is I want to install the package without modifying either file.

This doesn't make sense to me. Why does it add the package as a dependency of itself? And how can I prevent it? Or am I using it wrong?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source