From 47278ce787bd5eead5b6aeec7f53af19efa0b434 Mon Sep 17 00:00:00 2001 From: Jake Pusateri Date: Tue, 29 Sep 2026 14:30:34 +0000 Subject: [PATCH] docs: use wandb/core default branch for uidrift Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> --- .github/workflows/uidrift-scan.yml | 4 ++-- scripts/uidrift/config.py | 2 +- scripts/uidrift/scan.py | 2 +- scripts/uidrift/tests/test_ownership.py | 6 +++--- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/uidrift-scan.yml b/.github/workflows/uidrift-scan.yml index 2e356f53b1..04ebaf08d1 100644 --- a/.github/workflows/uidrift-scan.yml +++ b/.github/workflows/uidrift-scan.yml @@ -179,10 +179,10 @@ jobs: # blob content. On a blobless clone a one-day window spent 82 # seconds lazy-fetching and then died on the promisor remote. git -c "http.extraheader=${header}" clone --quiet \ - --no-checkout --single-branch --branch master \ + --no-checkout --single-branch \ https://github.com/wandb/core.git "$CORE_REPO" - git -C "$CORE_REPO" log -1 --format='wandb/core master at %h (%ci)' origin/master + git -C "$CORE_REPO" log -1 --format='wandb/core default branch at %h (%ci)' origin/HEAD - name: Scan for label drift id: scan diff --git a/scripts/uidrift/config.py b/scripts/uidrift/config.py index 0b20448e99..04278d4604 100644 --- a/scripts/uidrift/config.py +++ b/scripts/uidrift/config.py @@ -68,7 +68,7 @@ def path(self) -> Path: owner_repo="wandb/core", local_path_env="CORE_REPO", local_path_default="~/core", - default_head="origin/master", + default_head="origin/HEAD", token_env="WANDB_CORE_TOKEN", ui_roots=("frontends/app/src",), ui_exts=(".tsx", ".jsx"), diff --git a/scripts/uidrift/scan.py b/scripts/uidrift/scan.py index a035b4f780..8522d9252a 100644 --- a/scripts/uidrift/scan.py +++ b/scripts/uidrift/scan.py @@ -201,7 +201,7 @@ def scan( # Resolved once for the whole run rather than per finding; the caches are # process-local, so a fresh run always re-reads them. `head` is passed so # ownership reads the same ref the range came from -- a `--head` scan whose - # reviewers were ranked against `origin/master` names the wrong people. + # reviewers were ranked against `origin/HEAD` names the wrong people. ownership.reset_caches(head=head) raw: list = [] diff --git a/scripts/uidrift/tests/test_ownership.py b/scripts/uidrift/tests/test_ownership.py index 340f233e87..3f14c98131 100644 --- a/scripts/uidrift/tests/test_ownership.py +++ b/scripts/uidrift/tests/test_ownership.py @@ -80,7 +80,7 @@ def setUpClass(cls) -> None: (repo / ".github").mkdir(parents=True, exist_ok=True) _commit(repo, ".github/CODEOWNERS", CODEOWNERS, "Ada Lovelace") - # config.SOURCE.default_head is origin/master, which a fresh repo lacks. + # config.SOURCE.default_head is origin/HEAD, which a fresh repo lacks. _git(repo, "update-ref", f"refs/remotes/{config.SOURCE.default_head}", "HEAD") @classmethod @@ -306,14 +306,14 @@ class TestHeadSelection(OwnershipTestCase): """Ownership must read the ref `scan` actually scanned. `scan` exposes `--head`, and both answers here come from git history, so a - scan of a non-default ref that ranked reviewers against `origin/master` + scan of a non-default ref that ranked reviewers against `origin/HEAD` would name people who never touched the commits in the range. """ @classmethod def setUpClass(cls) -> None: super().setUpClass() - # A ref origin/master does not contain: one more author on members.tsx + # A ref origin/HEAD does not contain: one more author on members.tsx # and a CODEOWNERS that routes the app to a different team. _git(cls.repo, "checkout", "-q", "-b", "feature") _commit(cls.repo, f"{UI}/members.tsx", "linus", "Linus Torvalds")