Skip to content

Publish stats to S3 instead of GitHub Pages - #11

Merged
Zethson merged 1 commit into
mainfrom
publish-stats-to-s3
Sep 3, 2026
Merged

Publish stats to S3 instead of GitHub Pages#11
Zethson merged 1 commit into
mainfrom
publish-stats-to-s3

Conversation

@Zethson

@ZethsonZethson commented Sep 3, 2026

Copy link
Copy Markdown
Member

Unblocks scverse/scverse.github.io#259.

stats.json and contributors.json only exist inside this repo's Pages deploy, which owns scverse.org/stats/ and so blocks the website from rendering that page itself. The scverse-stats bucket already allows anonymous reads, and this repo already has the OIDC role and the AWS_ROLE_ARN secret for it — the S3 steps were just left commented out.

So: upload output/ to s3://scverse-stats/ on main, drop the Pages deploy, and fix the rebuild trigger, which dispatched gh-pages.yml on this repo instead of on scverse/scverse.github.io.

Pages still has to be disabled in the repo settings afterwards, otherwise it keeps holding scverse.org/stats/.

Zethson added a commit to scverse/scverse.github.io that referenced this pull request Sep 3, 2026
scverse/stats keeps scverse.org/stats/ occupied for as long as it
deploys to Pages, and that is the path this page wants. Point both stats
fetches at the public scverse-stats bucket instead, which scverse/stats
uploads to in scverse/stats#11.
The generated JSON was only reachable through the Pages deploy of this
repo, which occupies scverse.org/stats/ and blocks the website from
rendering that page itself.
Upload output/ to the public scverse-stats bucket via the existing OIDC
role instead, and drop the Pages deploy. Also point the post-deploy
rebuild trigger at scverse/scverse.github.io, which is the repository
that actually has the gh-pages.yml workflow.
Zethson added a commit to scverse/scverse.github.io that referenced this pull request Sep 3, 2026
layouts/people/list.html conflicted because this branch predates the
people-page redesign and still carried the old teams layout. Took main's
version; the branch's only real edit to that file was the contributors
URL, which is reapplied.
layouts/shortcodes/stats.html reads the same contributors file for the
mission-page tiles, so it moves to the bucket too rather than leaving two
sources for one number.
The three fetches use try. The people page and the mission tiles drop
their contributor data rather than taking the site down with them; the
stats page cannot render without it, so it fails with a message naming
scverse/stats#11 instead of a bare Forbidden.
@Zethson
Zethson merged commit fb16adc into mainSep 3, 2026
Zethson added a commit to scverse/scverse.github.io that referenced this pull request Sep 3, 2026
* Build the stats page into the site
The stats page lived in scverse/stats with its own frontend, so it did
not look or navigate like the rest of scverse.org. This renders the same
data through the site's own layout, type and tiles, and links it from
the About menu.
stats.json and contributors.json are still produced by scverse/stats and
fetched at build time, the same way the packages page reads the ecosystem
registry. The data is a snapshot rather than a time series, so the page
is a set of numbers and a contributor list, not the growth charts the
issue imagined.
Refs #157.
* Colour the contribution bars and shorten the nav label
A dark neutral bar disappears under extensions that invert the page, so
use the blue from the Join button gradient. It is the only site hue
besides the cerise that clears 3:1 against the page, checked rather than
eyeballed.
"scverse in numbers" stays as the page title, but the menu entry reads
Statistics.
* Make the tiles that lead somewhere clickable, and drop the Impact group
Tiles with a destination are anchors and pick up the hover the rest of
the site uses — background shift plus a small scale. Only eight of the
thirteen link: a tile links out where the destination shows the same
number, so Zulip, Bluesky, the org people page, /people, the two
packages sections and the org page do, while the pull request and issue
counts do not, since a GitHub search covers all 99 org repos and these
numbers cover 12.
Issues move in with the packages, citations join the community, and the
daily download average goes back under the headline figure, which leaves
two groups instead of three and nothing stranded.
* Show LinkedIn followers when the registry has them
scverse/stats#9 adds the field. It is scraped from the logged-out
company page, so a run that gets blocked will not have it, and the tile
is behind a `with` rather than assuming it is there.
* Pair citations with the download figure, expand the contributor list
Citations sat awkwardly among the community tiles; they belong next to
downloads, so the two impact numbers now share the headline row with the
citation count set smaller.
The remaining contributors go behind a details element rather than a
count of people you cannot see. It needs no JavaScript, and the avatars
in it are not fetched until it is opened.
Drop the sources footnote: the intro already credits scverse/stats, and
the contributor paragraph already says the counts are core-only.
* Give both headline figures the same size
* Say the ranking is by commits without calling anyone busiest
* Read stats from the public S3 bucket
scverse/stats keeps scverse.org/stats/ occupied for as long as it
deploys to Pages, and that is the path this page wants. Point both stats
fetches at the public scverse-stats bucket instead, which scverse/stats
uploads to in scverse/stats#11.
* Read stats from the dev bucket
The role behind AWS_ROLE_ARN only covers scverse-stats-dev, so that is
where scverse/stats publishes until the pipeline is proven. Tracked in
scverse/stats#13.
Sign up for freeto 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

@Zethson