BigQuery GitHub data: How to handle repo name changes?

My goal is to track the total number of stars of my repo. However, its repo.name changed over time. How to achieve this with the githubarchive dataset?

  • could not resolve host github.com error while cloning remote repository in git
  • Enforcing PEP-8'ish formatting in Github commits
  • Cannot clone project from github
  • web2py git integration - localhost & pythonanywhere
  • Git: Pushing to repo error. (Error updating submodules)
  • When I enter ssh-keygen -t rsa -C “your@email.com” in git it gives “Too many arguments” error
  • Git - checkout a single directory out of a repo - error: pathspec did not match any file(s) known to git
  • Git/GitHub branch merge
  • Automatic Commit and Push to GitHub from Android Studio
  • How to get a branch into a forked repo from the original repo in github
  • git diffrence between clone repo and clone rep.git
  • Is it ok to keep a (considerably small) number of images/binary data in a git repo?
  • One Solution collect form web for “BigQuery GitHub data: How to handle repo name changes?”

    (related to https://stackoverflow.com/a/42930963/132438)

    GitHub project names go through changes, so instead of querying by name it’s safer to query by id. You could look for a project id in a separate query, or do it altogether in a query like this:

    SELECT 
      COUNT(*) naive_count,
      COUNT(DISTINCT actor.id) unique_by_actor_id, 
      COUNT(DISTINCT actor.login) unique_by_actor_login 
    FROM `githubarchive.month.*` 
    WHERE repo.id = (
      SELECT repo.id 
      FROM `githubarchive.month.201702` 
      WHERE repo.name='bazelbuild/bazel' 
      LIMIT 1)
    AND type = "WatchEvent"
    
    Git Baby is a git and github fan, let's start git clone.