Repository: pypa/pipenv

Issue:
Local inter-dependency resolution fails
### Issue description

Lets say I have two local dependencies, where one of the packages depends on the other: 
```
[packages]
test-package-pipenv-base = {path = "./test_package_pipenv_base"}
test-package-pipenv-with-dependency = {path = "./test_package_pipenv_with_dependency"}
```
This basically works (`pipenv install --skip-lock` will install everything into the environment just fine), but `pipenv lock` fails.
 
```
pipenv.exceptions.ResolutionFailure: ERROR: Could not find a version that matches test_package_pipenv_base (from -r /var/folders/55/rh929wp96y71h796rv7tddl00000gn/T/pipenve4tn0hajrequirements/pipenv-4pdm4ur9-constraints.txt (line 2))
No versions found
Was https://pypi.org/si
```

### Expected result

This should work. Dependency resolution should identify that the package is sourced locally and not try to source it from upstream repos. 

This works fine when installing a requirements.txt file with inter-dependent local packages. 

### Actual result

` pipenv lock --verbose`:
```
Locking [dev-packages] dependencies...
Locking [packages] dependencies...
Building requirements...
Resolving dependencies...
⠇ Locking...
                          ROUND 1
✘ Locking Failed!
Current constraints:
  requests (from -r /var/folders/55/rh929wp96y71h796rv7tddl00000gn/T/pipenve4tn0hajrequirements/pipenv-4pdm4ur9-constraints.txt (line 3))
  test_package_pipenv_base (from -r /var/folders/55/rh929wp96y71h796rv7tddl00000gn/T/pipenve4tn0hajrequirements/pipenv-4pdm4ur9-constraints.txt (line 2))

Finding the best candidates:
  found candidate requests==2.26.0 (constraint was <any>)
Traceback (most recent call last):
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 825, in resolve
    results = self.resolver.resolve(max_rounds=environments.PIPENV_MAX_ROUNDS)
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/patched/piptools/resolver.py", line 180, in resolve
    has_changed, best_matches = self._resolve_one_round()
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/patched/piptools/resolver.py", line 260, in _resolve_one_round
    best_matches = {self.get_best_match(ireq) for ireq in constraints}
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/patched/piptools/resolver.py", line 260, in <setcomp>
    best_matches = {self.get_best_match(ireq) for ireq in constraints}
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/patched/piptools/resolver.py", line 319, in get_best_match
    best_match = self.repository.find_best_match(
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/patched/piptools/repositories/pypi.py", line 205, in find_best_match
    raise NoCandidateFound(ireq, all_candidates, self.finder)
pipenv.patched.piptools.exceptions.NoCandidateFound: Could not find a version that matches test_package_pipenv_base (from -r /var/folders/55/rh929wp96y71h796rv7tddl00000gn/T/pipenve4tn0hajrequirements/pipenv-4pdm4ur9-constraints.txt (line 2))
No versions found
Was https://pypi.org/simple reachable?

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 764, in <module>
    main()
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 758, in main
    _main(parsed.pre, parsed.clear, parsed.verbose, parsed.system, parsed.write,
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 741, in _main
    resolve_packages(pre, clear, verbose, system, write, requirements_dir, packages, dev)
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 702, in resolve_packages
    results, resolver = resolve(
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 684, in resolve
    return resolve_deps(
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 1397, in resolve_deps
    results, hashes, markers_lookup, resolver, skipped = actually_resolve_deps(
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 1110, in actually_resolve_deps
    resolver.resolve()
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 835, in resolve
    raise ResolutionFailure(message=str(e))
pipenv.exceptions.ResolutionFailure: ERROR: Could not find a version that matches test_package_pipenv_base (from -r /var/folders/55/rh929wp96y71h796rv7tddl00000gn/T/pipenve4tn0hajrequirements/pipenv-4pdm4ur9-constraints.txt (line 2))
No versions found
Was https://pypi.org/simple reachable?
ROUND 1
Current constraints:
  requests (from -r /var/folders/55/rh929wp96y71h796rv7tddl00000gn/T/pipenve4tn0hajrequirements/pipenv-4pdm4ur9-constraints.txt (line 3))
  test_package_pipenv_base (from -r /var/folders/55/rh929wp96y71h796rv7tddl00000gn/T/pipenve4tn0hajrequirements/pipenv-4pdm4ur9-constraints.txt (line 2))

Finding the best candidates:
  found candidate requests==2.26.0 (constraint was <any>)
Traceback (most recent call last):
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 825, in resolve
    results = self.resolver.resolve(max_rounds=environments.PIPENV_MAX_ROUNDS)
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/patched/piptools/resolver.py", line 180, in resolve
    has_changed, best_matches = self._resolve_one_round()
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/patched/piptools/resolver.py", line 260, in _resolve_one_round
    best_matches = {self.get_best_match(ireq) for ireq in constraints}
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/patched/piptools/resolver.py", line 260, in <setcomp>
    best_matches = {self.get_best_match(ireq) for ireq in constraints}
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/patched/piptools/resolver.py", line 319, in get_best_match
    best_match = self.repository.find_best_match(
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/patched/piptools/repositories/pypi.py", line 205, in find_best_match
    raise NoCandidateFound(ireq, all_candidates, self.finder)
pipenv.patched.piptools.exceptions.NoCandidateFound: Could not find a version that matches test_package_pipenv_base (from -r /var/folders/55/rh929wp96y71h796rv7tddl00000gn/T/pipenve4tn0hajrequirements/pipenv-4pdm4ur9-constraints.txt (line 2))
No versions found
Was https://pypi.org/simple reachable?

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 764, in <module>
    main()
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 758, in main
    _main(parsed.pre, parsed.clear, parsed.verbose, parsed.system, parsed.write,
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 741, in _main
    resolve_packages(pre, clear, verbose, system, write, requirements_dir, packages, dev)
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 702, in resolve_packages
    results, resolver = resolve(
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 684, in resolve
    return resolve_deps(
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 1397, in resolve_deps
    results, hashes, markers_lookup, resolver, skipped = actually_resolve_deps(
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 1110, in actually_resolve_deps
    resolver.resolve()
  File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 835, in resolve
    raise ResolutionFailure(message=str(e))
pipenv.exceptions.ResolutionFailure: ERROR: Could not find a version that matches test_package_pipenv_base (from -r /var/folders/55/rh929wp96y71h796rv7tddl00000gn/T/pipenve4tn0hajrequirements/pipenv-4pdm4ur9-constraints.txt (line 2))
No versions found
Was https://pypi.org/simple reachable?
```

The FAQ says to try `pipenv lock --clear`:

```
Locking [dev-packages] dependencies...
Locking [packages] dependencies...
Building requirements...
Resolving dependencies...
✘ Locking Failed!
[ResolutionFailure]:   File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 741, in _main
[ResolutionFailure]:       resolve_packages(pre, clear, verbose, system, write, requirements_dir, packages, dev)
[ResolutionFailure]:   File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 702, in resolve_packages
[ResolutionFailure]:       results, resolver = resolve(
[ResolutionFailure]:   File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/resolver.py", line 684, in resolve
[ResolutionFailure]:       return resolve_deps(
[ResolutionFailure]:   File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 1397, in resolve_deps
[ResolutionFailure]:       results, hashes, markers_lookup, resolver, skipped = actually_resolve_deps(
[ResolutionFailure]:   File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 1110, in actually_resolve_deps
[ResolutionFailure]:       resolver.resolve()
[ResolutionFailure]:   File "/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv/utils.py", line 835, in resolve
[ResolutionFailure]:       raise ResolutionFailure(message=str(e))
[pipenv.exceptions.ResolutionFailure]: Warning: Your dependencies could not be resolved. You likely have a mismatch in your sub-dependencies.
  First try clearing your dependency cache with $ pipenv lock --clear, then try the original command again.
 Alternatively, you can use $ pipenv install --skip-lock to bypass this mechanism, then run $ pipenv graph to inspect the situation.
  Hint: try $ pipenv lock --pre if it is a pre-release dependency.
ERROR: Could not find a version that matches test_package_pipenv_base (from -r /var/folders/55/rh929wp96y71h796rv7tddl00000gn/T/pipenv0chdv3kgrequirements/pipenv-5y6vxldn-constraints.txt (line 2))
No versions found
Was https://pypi.org/simple reachable?
```

### Steps to replicate

- Create two local packages (name them anything, but the names must NOT exist in PyPi)
- Setup the second package to depend on the first (setup.py)
- `pipenv install --skip-lock <package1> <package2>` # should work
- `pipenv lock` # error

Note: both `pipenv graph` and `pip freeze` show the environment has the correct packages:
- `pipenv graph`
```
test-package-pipenv-with-dependency==0.1
  - test-package-pipenv-base [required: Any, installed: 0.1]
    - requests [required: Any, installed: 2.26.0]
      - certifi [required: >=2017.4.17, installed: 2021.5.30]
      - charset-normalizer [required: ~=2.0.0, installed: 2.0.4]
      - idna [required: >=2.5,<4, installed: 3.2]
      - urllib3 [required: >=1.21.1,<1.27, installed: 1.26.6]
```
- `pipenv run pip freeze`
```
certifi==2021.5.30
charset-normalizer==2.0.4
idna==3.2
requests==2.26.0
test-package-pipenv-base @ file:///issue/test_package_pipenv_base
test-package-pipenv-with-dependency @ file:///issue/test_package_pipenv_with_dependency
urllib3==1.26.6
```

-------------------------------------------------------------------------------

Please run `$ pipenv --support`, and paste the results here. Don't put backticks (`` ` ``) around it! The output already contains Markdown formatting.

<details><summary>$ pipenv --support</summary>

Pipenv version: `'2021.5.29'`

Pipenv location: `'/Users/user1/.pyenv/versions/3.8.9/lib/python3.8/site-packages/pipenv'`

Python location: `'/Users/user1/.pyenv/versions/3.8.9/bin/python3.8'`

Python installations found:

  - `3.9.6`: `/usr/local/bin/python3`
  - `3.9.6`: `/usr/local/bin/python3.9`
  - `3.8.9`: `/Users/user1/.pyenv/versions/3.8.9/bin/python3`
  - `3.8.9`: `/Users/user1/.pyenv/versions/3.8.9/bin/python3`
  - `3.8.9`: `/Users/user1/.pyenv/versions/3.8.9/bin/python3.8`
  - `3.8.2`: `/usr/bin/python3`
  - `2.7.16`: `/usr/bin/python2`
  - `2.7.16`: `/usr/bin/python2.7`

---------------------------

Contents of `Pipfile` ('/issue/Pipfile'):

```toml
[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"

[packages]
test-package-pipenv-base = {path = "./test_package_pipenv_base"}
test-package-pipenv-with-dependency = {path = "./test_package_pipenv_with_dependency"}

[dev-packages]

[requires]
python_version = "3.8"

```


Contents of `Pipfile.lock` ('/issue/Pipfile.lock'):

```json
{
    "_meta": {
        "hash": {
            "sha256": "fa874ddda6051420be8b7056cdf0f937e60586ab4b7f56d0c552bd25a81d06da"
        },
        "pipfile-spec": 6,
        "requires": {
            "python_version": "3.8"
        },
        "sources": [
            {
                "name": "pypi",
                "url": "https://pypi.org/simple",
                "verify_ssl": true
            }
        ]
    },
    "default": {
        "certifi": {
            "hashes": [
                "sha256:2bbf76fd432960138b3ef6dda3dde0544f27cbf8546c458e60baf371917ba9ee",
                "sha256:50b1e4f8446b06f41be7dd6338db18e0990601dce795c2b1686458aa7e8fa7d8"
            ],
            "version": "==2021.5.30"
        },
        "charset-normalizer": {
            "hashes": [
                "sha256:0c8911edd15d19223366a194a513099a302055a962bca2cec0f54b8b63175d8b",
                "sha256:f23667ebe1084be45f6ae0538e4a5a865206544097e4e8bbcacf42cd02a348f3"
            ],
            "markers": "python_version >= '3'",
            "version": "==2.0.4"
        },
        "idna": {
            "hashes": [
                "sha256:14475042e284991034cb48e06f6851428fb14c4dc953acd9be9a5e95c7b6dd7a",
                "sha256:467fbad99067910785144ce333826c71fb0e63a425657295239737f7ecd125f3"
            ],
            "markers": "python_version >= '3'",
            "version": "==3.2"
        },
        "requests": {
            "hashes": [
                "sha256:6c1246513ecd5ecd4528a0906f910e8f0f9c6b8ec72030dc9fd154dc1a6efd24",
                "sha256:b8aa58f8cf793ffd8782d3d8cb19e66ef36f7aba4353eec859e74678b01b07a7"
            ],
            "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5'",
            "version": "==2.26.0"
        },
        "test-package-pipenv-base": {
            "path": "./test_package_pipenv_base",
            "version": "==0.1"
        },
        "urllib3": {
            "hashes": [
                "sha256:39fb8672126159acb139a7718dd10806104dec1e2f0f6c88aab05d17df10c8d4",
                "sha256:f57b4c16c62fa2760b7e3d97c35b255512fb6b59a259730f36ba32ce9f8e342f"
            ],
            "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4' and python_version < '4'",
            "version": "==1.26.6"
        }
    },
    "develop": {}
}

```
</details>



Discussion:
@jyoungs Could you provide your sample setup.py that you used to help reproduce this issue?
@matteius I believe this is a minimal reproduction example: https://github.com/duailibe/pipenv-local-deps-repro

EDIT: Added a working example using requirements.txt
Also this might be a duplicate of #4553
Probably also the same issues as in #4323
I believe this was resolved, can you check with `pipenv=2022.8.17`?
Just tested with https://github.com/duailibe/pipenv-local-deps-repro and still gives the same error

<details>
<summary>Error</summary>

```
❯ pipenv lock --verbose
Locking [packages] dependencies...
Building requirements...
Resolving dependencies...
Reporter.starting()
INFO:pipenv.patched.pip._internal.resolution.resolvelib.reporter:Reporter.starting()
Reporter.adding_requirement(SpecifierRequirement('test-package-pipenv-base'), None)
INFO:pipenv.patched.pip._internal.resolution.resolvelib.reporter:Reporter.adding_requirement(SpecifierRequirement('test-package-pipenv-base'), None)
CRITICAL:pipenv.patched.pip._internal.resolution.resolvelib.factory:Could not find a version that satisfies the requirement test-package-pipenv-base (from versions: none)
Traceback (most recent call last):
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/patched/pip/_vendor/resolvelib/resolvers.py", line 348, in resolve
    self._add_to_criteria(self.state.criteria, r, parent=None)
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/patched/pip/_vendor/resolvelib/resolvers.py", line 173, in _add_to_criteria
    raise RequirementsConflicted(criterion)
pipenv.patched.pip._vendor.resolvelib.resolvers.RequirementsConflicted: Requirements conflict: SpecifierRequirement('test-package-pipenv-base')
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/patched/pip/_internal/resolution/resolvelib/resolver.py", line 92, in resolve
    result = self._result = resolver.resolve(
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/patched/pip/_vendor/resolvelib/resolvers.py", line 481, in resolve
    state = resolution.resolve(requirements, max_rounds=max_rounds)
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/patched/pip/_vendor/resolvelib/resolvers.py", line 350, in resolve
    raise ResolutionImpossible(e.criterion.information)
pipenv.patched.pip._vendor.resolvelib.resolvers.ResolutionImpossible: [RequirementInformation(requirement=SpecifierRequirement('test-package-pipenv-base'), parent=None)]
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/utils/resolver.py", line 721, in resolve
    results = resolver.resolve(self.constraints, check_supported_wheels=False)
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/patched/pip/_internal/resolution/resolvelib/resolver.py", line 101, in resolve
    raise error from e
pipenv.patched.pip._internal.exceptions.DistributionNotFound: No matching distribution found for test-package-pipenv-base
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/resolver.py", line 858, in <module>
    main()
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/resolver.py", line 844, in main
    _main(
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/resolver.py", line 824, in _main
    resolve_packages(
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/resolver.py", line 772, in resolve_packages
    results, resolver = resolve(
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/resolver.py", line 751, in resolve
    return resolve_deps(
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/utils/resolver.py", line 1126, in resolve_deps
    results, hashes, markers_lookup, resolver, skipped = actually_resolve_deps(
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/utils/resolver.py", line 919, in actually_resolve_deps
    resolver.resolve()
  File "/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv/utils/resolver.py", line 723, in resolve
    raise ResolutionFailure(message=str(e))
pipenv.exceptions.ResolutionFailure: ERROR: No matching distribution found for test-package-pipenv-base
✘ Locking Failed! 
```
</details>

<details><summary>$ pipenv --support</summary>

Pipenv version: `'2022.8.17'`

Pipenv location: `'/Users/lucas/.local/pipx/venvs/pipenv/lib/python3.10/site-packages/pipenv'`

setuptools version: `'65.0.2'`

Python location: `'/Users/lucas/.local/pipx/venvs/pipenv/bin/python'`

OS Name: `'posix'`

User pip version: `'22.2.2'`

user Python installations found:

  - `3.10.0`: `/Users/lucas/.asdf/installs/python/3.10.0/bin/python3`
  - `3.9.13`: `/opt/homebrew/bin/python3`
  - `3.9.13`: `/opt/homebrew/bin/python3.9`
  - `3.8.12`: `/Users/lucas/.asdf/installs/python/3.8.12/bin/python3`
  - `3.8.2`: `/usr/bin/python3`
  - `2.7.18`: `/Users/lucas/.asdf/installs/python/2.7.18/bin/python`
  - `2.7.16`: `/usr/bin/python`
  - `2.7.16`: `/usr/bin/python2`
  - `2.7.16`: `/usr/bin/python2.7`

PEP 508 Information:

```
{'implementation_name': 'cpython',
 'implementation_version': '3.10.0',
 'os_name': 'posix',
 'platform_machine': 'arm64',
 'platform_python_implementation': 'CPython',
 'platform_release': '20.6.0',
 'platform_system': 'Darwin',
 'platform_version': 'Darwin Kernel Version 20.6.0: Wed Nov 10 22:23:05 PST '
                     '2021; root:xnu-7195.141.14~1/RELEASE_ARM64_T8101',
 'python_full_version': '3.10.0',
 'python_version': '3.10',
 'sys_platform': 'darwin'}
```

System environment variables:

  - `PWD`
  - `ASDF_DIR`
  - `USER`
  - `LC_ALL`
  - `XPC_SERVICE_NAME`
  - `EDITOR`
  - `PATH`
  - `SSH_AUTH_SOCK`
  - `TERM`
  - `XPC_FLAGS`
  - `TERM_PROGRAM_VERSION`
  - `TMPDIR`
  - `LOGNAME`
  - `LANG`
  - `__CFBundleIdentifier`
  - `LC_CTYPE`
  - `SHELL`
  - `VIRTUAL_ENV_DISABLE_PROMPT`
  - `SHLVL`
  - `TERM_SESSION_ID`
  - `HOME`
  - `TERM_PROGRAM`
  - `__CF_USER_TEXT_ENCODING`
  - `PIP_SHIMS_BASE_MODULE`
  - `PIP_DISABLE_PIP_VERSION_CHECK`
  - `PIP_PYTHON_PATH`
  - `PYTHONDONTWRITEBYTECODE`
  - `PYTHONFINDER_IGNORE_UNSUPPORTED`

Pipenv–specific environment variables:


Debug–specific environment variables:

  - `PATH`: `/Users/lucas/.asdf/shims:/opt/homebrew/opt/asdf/libexec/bin:/Users/lucas/.dotfiles/bin:/Users/lucas/.local/bin:/opt/homebrew/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin:/Users/lucas/Library/Android/sdk/tools`
  - `SHELL`: `/opt/homebrew/bin/fish`
  - `EDITOR`: `vim`
  - `LANG`: `en_US.UTF-8`
  - `PWD`: `/Users/lucas/Code/pipenv-local-deps-repro`


---------------------------

Contents of `Pipfile` ('/Users/lucas/Code/pipenv-local-deps-repro/Pipfile'):

```toml
[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"

[packages]
test-package-pipenv-base = {path = "./test_package_pipenv_base"}
test-package-pipenv-with-dependency = {path = "./test_package_pipenv_with_dependency"}

[dev-packages]

[requires]
python_version = "3.10"

```

</details>

@duailibe If you add `editable = "true"` to those Pipfile entries it should work.

Resolving patch:
diff --git a/pipenv/project.py b/pipenv/project.py
--- a/pipenv/project.py
+++ b/pipenv/project.py
@@ -584,7 +584,7 @@ def get_editable_packages(self, dev=False):
         packages = {
             k: v
             for k, v in self.parsed_pipfile.get(section, {}).items()
-            if is_editable(k) or is_editable(v)
+            if is_editable(v)
         }
         return packages
 
diff --git a/pipenv/utils/dependencies.py b/pipenv/utils/dependencies.py
--- a/pipenv/utils/dependencies.py
+++ b/pipenv/utils/dependencies.py
@@ -337,7 +337,7 @@ def is_required_version(version, specified_version):
 
 def is_editable(pipfile_entry):
     if hasattr(pipfile_entry, "get"):
-        return pipfile_entry.get("editable", False) and any(
+        return pipfile_entry.get("editable", False) or any(
             pipfile_entry.get(key) for key in ("file", "path") + VCS_LIST
         )
     return False


Test patch: