INNER CODE UNIT · Python

path

epigen/MrBiomics · helpers/MrBiomics_context_crawler.py:94

      path = path[:-4]
  return path


def github_headers(token: Optional[str]) -> dict[str, str]:
  headers = {
      "Accept": "application/vnd.github+json",
      "User-Agent": "MrBiomics-context-crawler",
  }
  if token:
      headers["Authorization"] = f"Bearer {token}"
  return headers


def fetch_latest_commit(repo_url: str, token: Optional[str] = None) -> tuple[str, str]:
  """Use the GitHub API to look up the default-branch commit for a normal repo."""
  repo_id = repo_identifier(repo_url)
  if not repo_id:

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…