Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lack of Internal Dependency Files from python source project #10

Closed
JuneLyoo opened this issue Jul 4, 2023 · 1 comment
Closed

Lack of Internal Dependency Files from python source project #10

JuneLyoo opened this issue Jul 4, 2023 · 1 comment
Assignees

Comments

@JuneLyoo
Copy link

JuneLyoo commented Jul 4, 2023

Hello,

During the project setup, I noticed that a source project does not have any internal dependency files.

I propose the following solution to generate a list of dependencies for this project:

Solution Steps:

  1. Use Pipdeptree to generate a list of dependencies.

Install pipdeptree:

$ pip install pipdeptree
  1. As an example, let's say we want to generate a dependency tree for a package named 'requests'. Execute the following command:
$ pipdeptree -p requests

This should provide an output similar to the following:

requests==2.23.0
  - certifi [required: >=2017.4.17, installed: 2020.4.5.1]
  - chardet [required: >=3.0.2,<4, installed: 3.0.4]
  - idna [required: >=2.5,<3, installed: 2.9]
  - urllib3 [required: >=1.21.1,<1.26,!=1.25.1,!=1.25.0, installed: 1.25.9]
  1. Next, copy these dependencies and their version information into a requirements.txt file, like so:
certifi>=2017.4.17
chardet>=3.0.2,<4
idna>=2.5,<3
urllib3>=1.21.1,<1.26,!=1.25.1,!=1.25.0
  1. Lastly, you can download the dependencies to the current directory without installing them by using the following command:
(current directory) $ pip download -r requirements.txt

This method will allow us make the project set-up smoother for python source projects. Thanks.

original link: https://www.activestate.com/resources/quick-reads/how-to-download-python-dependencies/

@joshpxyne joshpxyne self-assigned this Jul 4, 2023
@joshpxyne
Copy link
Owner

Added requirements.txt files to each of the benchmarks and added instructions in readme, should be sufficient

6ae7cc2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants