Skip to content

fix(webhook): reconcile repository renames by GitHub id#86

Closed
volcano303 wants to merge 1 commit into
entrius:testfrom
volcano303:fix/repo-rename-reconcile-test
Closed

fix(webhook): reconcile repository renames by GitHub id#86
volcano303 wants to merge 1 commit into
entrius:testfrom
volcano303:fix/repo-rename-reconcile-test

Conversation

@volcano303
Copy link
Copy Markdown
Contributor

Summary

  • Add repos.github_repo_id so the mirror can identify repositories by GitHub's stable repository ID.
  • Reconcile webhook payloads whose repository.full_name changed by moving existing repo-keyed mirror rows to the new full name before handler dispatch.
  • Route installation add/remove events through the same identity path so future payloads keep the stable repo ID populated.

Related Issues

Fixes #72

Type of Change

  • Bug fix
  • New feature
  • Refactor
  • Documentation
  • Other (describe below)

Testing

  • npm run format:check
  • npm run lint
  • npm run build
  • git diff --check

Checklist

  • I have read the Contributing Guide
  • Code builds without errors
  • New and existing tests pass (if applicable)
  • Documentation updated (if applicable)
  • No unnecessary dependencies added

@xiao-xiao-mao xiao-xiao-mao Bot added the bug Something isn't working label May 13, 2026
@anderdc
Copy link
Copy Markdown
Collaborator

anderdc commented May 14, 2026

Not pursuing — repository renames on subnet-tracked repos are vanishingly rare, and if one ever does happen an operator can repair the rows with a one-shot SQL UPDATE per repo-keyed table in less time than reviewing this PR. The cost of automatic reconciliation in the webhook hot path (extra SELECT per event, schema change, +182 lines on the trust surface) outweighs the cost of manual repair on the unlikely day it triggers. Closing.

@anderdc anderdc closed this May 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Repository rename or transfer can stop webhook ingestion due to stale repo_full_name

2 participants