Skip to content

Comments

Add a GitHub repository struct to uv-git#10768

Merged
charliermarsh merged 2 commits intomainfrom
charlie/github
Jan 20, 2025
Merged

Add a GitHub repository struct to uv-git#10768
charliermarsh merged 2 commits intomainfrom
charlie/github

Conversation

@charliermarsh
Copy link
Member

Summary

This is useful for #10765, but we already have one usage today, so carving it out into a standalone PR.

@charliermarsh charliermarsh added the internal A refactor or improvement that is not user-facing label Jan 20, 2025
} else {
// Usually response_code == 404 if the repository does not exist, and
// response_code == 422 if exists but GitHub is unable to resolve the
// requested rev.
Copy link
Member Author

Choose a reason for hiding this comment

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

This is in the wrong place. 400-level errors are raised by response.error_for_status_ref()?!

/// repository, like `astral-sh`.
pub owner: &'a str,
/// The `repo` field for the repository, i.e., the name of the repository, like `uv`.
pub repo: &'a str,
Copy link
Member Author

Choose a reason for hiding this comment

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

Uses the terminology of the GitHub API.

@charliermarsh charliermarsh enabled auto-merge (squash) January 20, 2025 14:29
@charliermarsh charliermarsh merged commit 9e6e1e5 into main Jan 20, 2025
63 checks passed
@charliermarsh charliermarsh deleted the charlie/github branch January 20, 2025 14:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

internal A refactor or improvement that is not user-facing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants