Skip to content

feat: publish secure dynamic repository metrics - #9

Merged
JNHFlow21 merged 1 commit into
mainfrom
codex/secure-repository-metrics-20260810
Aug 11, 2026
Merged

feat: publish secure dynamic repository metrics#9
JNHFlow21 merged 1 commit into
mainfrom
codex/secure-repository-metrics-20260810

Conversation

@JNHFlow21

@JNHFlow21 JNHFlow21 commented Aug 11, 2026

Copy link
Copy Markdown
Owner

Summary

  • replace the restricted Star History embed with a repository-owned white sketch-style SVG
  • refresh stars, forks, commits, visitors, cloners, and clone totals using GitHub Actions
  • publish generated output on an orphan metrics branch without embedding a long-lived token
  • add renderer and README contract tests

Validation

  • PYTHONPATH=src python3 -m unittest discover -s tests -v (77 passed)
  • python3 scripts/privacy_scan.py
  • actionlint .github/workflows/repository-metrics.yml
  • local live-data SVG render and visual review

@JNHFlow21
JNHFlow21 merged commit 2c9982f into main Aug 11, 2026
7 checks passed
@JNHFlow21
JNHFlow21 deleted the codex/secure-repository-metrics-20260810 branch August 11, 2026 03:08

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a6b0859ab7

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

- uses: actions/checkout@v7
- name: Render privacy-safe metrics SVG
env:
GITHUB_TOKEN: ${{ github.token }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Supply a token permitted to read repository traffic

The workflow GITHUB_TOKEN can only receive the permissions exposed under permissions:, and contents: write does not grant the Administration (read) permission required by the /traffic/views and /traffic/clones endpoints called by fetch_snapshot(). Consequently, every watch, scheduled, or manual run reaches those calls with ${{ github.token }} and receives a 403 before generating or publishing the SVG; use a GitHub App or other credential with repository traffic access, keeping the branch-push credential separate if necessary.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant