question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Pipenv 2020 error's out not finding the requirement.txt

See original GitHub issue

Issue description

On a empty folder installing - pipenv install thoth-sourcemanagement Error’s out stating missing requirements.txt However works as expected with pipenv 2018 version.

Steps to replicate

Environment - Fedora 32 You can also replicate the error on a katacoda environment - https://www.katacoda.com/courses/ubuntu/playground1804

Try installing the following Pipfile with pipenv 2020 Provide the steps to replicate (which usually at least includes the commands and the Pipfile).

[[source]]
name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true

[dev-packages]

[packages]
thoth-sourcemanagement = "*"

[requires]
python_version = "3.6"

image

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
techalchemycommented, May 28, 2020

I did a bit of extra work to try parsing setup.py without breaking, and it seems to have paid off in your case. For this case and others like it, pipenv falls back to requirementslib which ultimately tries to build a wheel using the pep517 wheel builder and, if unspecified, the setuptools legacy build backend. If that is successful we will consume metadata from the built wheel – this is obviously much less efficient than just parsing textual metadata that is declared in a manifest, but it’s kind of neat that it works again ^^

I’ll close this issue for now as I was able to confirm this myself directly with requirementslib:

>>> from requirementslib.models.requirements import Requirement                                                                                            
>>> r = Requirement.from_line("-e .")                                                                                                                      
>>> r.run_requires()                                                                                                                                       
{'name': 'thoth-sourcemanagement', 'version': '0.2.9', 'base_dir': '/tmp/reqlib-srczugi9sxi/source-management', 'ireq': <InstallRequirement object: thoth-sourcemanagement==0.2.9@ file:///tmp/source-management from file:///tmp/source-management editable=True>, 'build_backend': 'setuptools.build_meta:__legacy__', 'build_requires': ('wheel', 'setuptools>=40.8'), 'requires': {'ogr': Requirement.parse('ogr'), 'requests': Requirement.parse('requests'), 'delegator.py': Requirement.parse('delegator.py')}, 'python_requires': '>=3.6', 'extra_kwargs': {'build_dir': '/tmp/reqlib-buildyrhlbxd0', 'src_dir': '/tmp/reqlib-srczugi9sxi', 'download_dir': '/home/techalchemy/.cache/pipenv/pkgs', 'wheel_download_dir': '/home/techalchemy/.cache/pipenv/wheels'}, 'setup_cfg': PosixPath('/tmp/reqlib-srczugi9sxi/source-management/setup.cfg'), 'setup_py': PosixPath('/tmp/reqlib-srczugi9sxi/source-management/setup.py'), 'pyproject': PosixPath('/tmp/reqlib-srczugi9sxi/source-management/pyproject.toml')}
0reactions
taybincommented, May 28, 2020

FWIW, I can’t duplicate this anymore, even without updating my libraries to not use a requirements.txt file. Still planning on doing that, but not having my builds break is also a relief. 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

Common Pipenv Errors and How to Solve Them
Pipenv looks for the package you specify, whether it exists or not. You see the following errors and many more in the terminal...
Read more >
[pipenv.exceptions.InstallError]: ERROR: Could not find a ...
We know, the Django==2.2 is there and it seems the flag --python 3.6 is not using by the pipenv command. complete error traceback....
Read more >
Advanced Usage of Pipenv - Read the Docs
Dependencies of wheels provided in a Pipfile will not be captured by $ pipenv lock . There are some known issues with using...
Read more >
Pipenv
The problems that Pipenv seeks to solve are multi-faceted: You no longer need to use pip and virtualenv separately. They work together. Managing...
Read more >
pipenv Documentation
Managing a requirements.txt file can be problematic, so Pipenv uses Pipfile and ... Find out what's changed upstream: $ pipenv update --outdated.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found