FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

On Travis, follow package dependency graph to expand package list. by dhermes · Pull Request #2487 · googleapis/google-cloud-python · GitHub

On Travis, follow package dependency graph to expand package list. - #2487

Closed
dhermes wants to merge 2 commits into
googleapis:masterfrom
dhermes:compute-dep-graph
Closed

On Travis, follow package dependency graph to expand package list.#2487
dhermes wants to merge 2 commits into
googleapis:masterfrom
dhermes:compute-dep-graph

Conversation

dhermes commented Oct 4, 2016

Copy link
Copy Markdown
Contributor

To make computing the dependency graph easier I moved the requirements of each package into a requirements.txt file.

I'm happy to instead write a custom setup.py parser but decided that the route of less code was "better" in some sense.

googlebot added the cla: yes This human has signed the Contributor License Agreement. label Oct 4, 2016

Copy link
Copy Markdown
Contributor

@dhermes can you fix the conflicts?
Otherwise this LGTM.

Using boilerplate code snippet in each setup.py to load
the requirements.txt and adding the requirements.txt file to
MANIFEST.in file.
dhermes force-pushed the compute-dep-graph branch from 31d2f51 to f2b87af Compare October 4, 2016 17:25

tseaver left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

I am -1 on the "parse requirements.txt" approach:

  • The requirements.txt format is effectively an internal implementation detail of pip: they provide no public API for parsing it.
  • In the words of the PyPA docs and @dstufft, it is intended to support "application deployments", not as a substitute driver for install_requires / "library requirements."

I believe we would be better off leaving install_requires as the definitive version spec for the library, and using the pkg_resources API in our scripts to get the dependency metadata we need.

/cc @jonparrott

dhermes commented Oct 4, 2016

Copy link
Copy Markdown
Contributor Author

@tseaver SGTM. @jonparrott and I discussed and I view pkg_resources as inferior to parsing because it requires having those packages installed somewhere before we decide we want to run those tests.

I'll whip up a proof of concept that parses our setup.py files, assuming some kind of format, and enforces the assumptions with errors.

tseaver commented Oct 4, 2016

Copy link
Copy Markdown
Contributor

@dhermes To do the analysis on Travis, we are going to have them installed somewhere, likely into a tox environment. If we add a console_script (maybe as an extra) which is installed into the environment, then we can get the metadata from it.

dhermes commented Oct 4, 2016

Copy link
Copy Markdown
Contributor Author

@tseaver PTAL at #2498

dhermes closed this Oct 4, 2016
dhermes deleted the compute-dep-graph branch October 4, 2016 22:57
parthea pushed a commit that referenced this pull request Nov 24, 2025
Co-authored-by: Victor Chudnovsky <vchudnov@google.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
parthea pushed a commit that referenced this pull request Apr 1, 2026
feat: update image to
us-central1-docker.pkg.dev/cloud-sdk-librarian-prod/images-prod/python-librarian-generator@sha256:160860d189ff1c2f7515638478823712fa5b243e27ccc33a2728669fa1e2ed0c
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: yes This human has signed the Contributor License Agreement. testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants


Back | FazBrowse Home | New Git URL