feat: download cds get profiles from GitHub instead of local checkout - #493
Merged
Conversation
By design, `cds get` now fetches its source repository from GitHub rather than copying files from a local checkout: - Default (no flags): downloads this project's upstream repo at `main` via the GitHub tarball API (no `git` binary required). - `--remote <owner/repo>` or a github.com URL, plus optional `--ref <branch|tag|sha>`, fetches a specific fork/revision. - `--local <dir>` explicitly opts into using an existing local directory instead (mutually exclusive with --remote/--ref), for offline/dev workflows. Updates cli/getter.py, cli/main.py, README.md, and tests accordingly. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Bandit (B310) doesn't recognize ruff's `# noqa: S310` suppression syntax; it needs its own `# nosec B310` marker, matching the existing convention in cli/image_updates.py. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This was referenced Aug 24, 2026
Owner
Author
|
Review: LGTM ✅ (posted as a comment since GitHub doesn't allow self-approval) Reviewed the diff and CI (all 11 checks passing). The core design is solid:
Two independent reviews turned up a few non-blocking follow-ups, now tracked as separate issues so they don't hold up this PR:
None of these are security-critical or regressions in existing guarantees. Good to merge. |
RonaldHensbergen
added a commit
that referenced
this pull request
Aug 24, 2026
* chore(release): bump version to 0.5.1 * docs: finalize CHANGELOG [Unreleased] heading for 0.5.1 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * docs: note cds get GitHub-download breaking change in 0.5.1 changelog Addresses the missing-CHANGELOG-entry follow-up from #493 (issue #508). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: RonaldHensbergen <22539616+RonaldHensbergen@users.noreply.github.com> Co-authored-by: Ronald Hensbergen <r.hensbergen@regiogv.nl> Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
cds getpreviously copied a profile and its dependent module/runtime assets from a local checkout (the current repository, or--remote <local-path>). By design, it now downloads from GitHub instead:mainbranch via the GitHub tarball API (api.github.com/repos/{owner}/{repo}/tarball/{ref}) — nogitbinary required.--remote <owner/repo>or agithub.com/...URL, plus optional--ref <branch|tag|sha>: fetches a specific fork/revision from GitHub.--local <dir>: explicit opt-in to use an existing local directory instead of downloading (mutually exclusive with--remote/--ref), for offline/dev workflows.Changes
cli/getter.py: added GitHub remote parsing (owner/reposhorthand,github.comURLs,git@github.com:SSH form) and tarball download/extraction viaurllib+ stdlibtarfile(no new dependency).--localnow explicitly selects a local directory;fetch_profile()gainedrefandlocalparameters.cli/main.py:cds getgained--refand--localCLI flags;--remotehelp text updated to describe the new GitHub-only semantics.README.md: documented the new default download-from-GitHub behavior and flags.tests/test_getter.py/tests/test_main.py: updated existing local-repo tests to use--local/local=, and added coverage for GitHub remote parsing, default-remote download (mocked), explicit owner/repo + ref, download failure handling, unresolvable remote errors, and the--remote/--localmutual-exclusivity check.Testing
python -m unittest discover -s tests -p "test_*.py"— 536 tests, OKruff check .— all checks passednpx markdownlint-cli@0.49.0 README.md— clean