Skip to content

Conversation

AdamKorcz
Copy link
Contributor

@AdamKorcz AdamKorcz commented Aug 26, 2025

What kind of change does this PR introduce?

This adds a tagsHandler to the githubrepo client. The tagsHandler follows a similar procedure as the branchesHandler and reuses many of its utilities. The tagsHandler implements the following methods:

  1. init: Similar to branchesHandler's init.
  2. setup: Fetches all rulesets and tags of the repository and stores it.
  3. query: Returns a clients.RepoRef of a branch.
  4. getTags: Returns a slice of all tags as RepoRef's with their rulesets.
  5. getTag: Calls query and returns the RepoRef.

To implement this tagsHandler, I have had to make a number of changes:

  1. I have renamed BranchRef to RepoRef.
  2. I have renamed branch ref.
  3. I have renamed other similar types from being branch-specific to be logically usable for storing tag data.

Furthermore, I have added GetTag and ListTags methods to the repoclient interface and the clients that implement the repoclient. This is the most user-exposed the tagsHandler currently, and these two methods are not used anywhere. They are there to demonstrate the intent of how to use the githubrepo tagsHandler.

The PR is quite large as it is now, so I'd prefer to follow up with probes for this once it is merged.

(Is it a bug fix, feature, docs update, something else?)

What is the current behavior?

What is the new behavior (if this is a feature change)?**

  • Tests for the changes have been added (for bug fixes/features)

Which issue(s) this PR fixes

Fixes #10 and #2476

Special notes for your reviewer

Does this PR introduce a user-facing change?

For user-facing changes, please add a concise, human-readable release note to
the release-note

(In particular, describe what changes users might need to make in their
application as a result of this pull request.)

NONE

@AdamKorcz AdamKorcz requested a review from a team as a code owner August 26, 2025 19:26
@AdamKorcz AdamKorcz requested review from justaugustus and raghavkaul and removed request for a team August 26, 2025 19:26
@AdamKorcz AdamKorcz temporarily deployed to integration-test August 26, 2025 19:26 — with GitHub Actions Inactive
Copy link

codecov bot commented Aug 26, 2025

Codecov Report

❌ Patch coverage is 59.82533% with 92 lines in your changes missing coverage. Please review.
✅ Project coverage is 68.22%. Comparing base (353ed60) to head (fea6945).
⚠️ Report is 228 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4770      +/-   ##
==========================================
+ Coverage   66.80%   68.22%   +1.42%     
==========================================
  Files         230      251      +21     
  Lines       16602    19076    +2474     
==========================================
+ Hits        11091    13015    +1924     
- Misses       4808     5191     +383     
- Partials      703      870     +167     
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link

github-actions bot commented Sep 6, 2025

This pull request has been marked stale because it has been open for 10 days with no activity

@github-actions github-actions bot added the Stale label Sep 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

New check: Does the project use protected tags?, blocked on GitHub feature implementation.
1 participant