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.

Specify and install Python dependencies in a requirements.txt file

See original GitHub issue

Right now we have some Python source code checked into our repository. We should move away from that and over to pinned versions that we install via pip.

The install command should be:

python -m pip install --target pythonFiles --implementation py --no-deps -r requirements.txt

The requirements.txt files should be:

# Needs 'futures' for Python 2; see https://github.com/Microsoft/vscode-python/issues/2022 .
isort==4.3.4
parso==0.2.1
jedi==0.12.0
# Should probably start pinning ptvsd.
ptvsd

And with that we can drop almost all of the third-party code in pythonFiles that we have checked into our repo. This will require updating where we install ptvsd, though, as well as probably renaming/moving the requirements.txt file we already have in the top-level directory that specifies requirements for tests.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:1
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
DonJayamannecommented, Oct 23, 2018

Just wanted to ensure we do not forget about that requirement (for testing purposes), either way, I do agree with the suggestion.

1reaction
brettcannoncommented, Oct 22, 2018

@DonJayamanne I knew you were going to say that 😉 . That’s fine, but for general development and especially for building the extension we shouldn’t do that.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to use requirements.txt to install all dependencies in a ...
Remove matplotlib==1.3.1 from requirements.txt · Try to install with sudo apt-get install python-matplotlib · Run pip install -r requirements.txt (Python 2), or ...
Read more >
Managing Python Dependencies with Requirements.txt
This article will explain how unwanted packages sneak into your code, describe how to use requirements.txt files to ensure repeatable builds, ...
Read more >
The Python Requirements File and How to Create it
Use the pip install -r requirements.txt command to install all of the Python modules and packages listed in your requirements.txt file. This ...
Read more >
Manage dependencies using requirements.txt | IntelliJ IDEA ...
From the Tools menu, select Sync Python Requirements. · In the opened dialog, specify the name of the requirements file. · Select the...
Read more >
How to install Python packages with pip and requirements.txt
The following command will install the packages according to the configuration file requirements.txt . ... You can name the configuration file ...
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