Commit graph

6 commits

Author SHA1 Message Date
DESKTOP-RTLN3BA\$punk
b587a4f0a5 fix(analytics): count the 0.0.x rpm as an installer, and name the proxy's refreshes in stable*.yml
The 0.0.x rpms were classed other, so installer totals left out about 220
lifetime downloads; they are installers like the 2.x rpm. Only one snapshot
has reached PostHog with the old kind, and the dashboard tiles compute
growth per asset, so the switch moves no counts.

The stable*.yml docstring said one count per 2.x launch or Check now. The
website's update proxy also fetches each file itself, about 96 a day per
file, and 2.2.4+ checks reach GitHub only when they fall back.
2026-10-26 15:45:24 -07:00
DESKTOP-RTLN3BA\$punk
c1e16fa577 feat(analytics): count the rpm, install scripts, apt index and checksums
New release-stats kinds installer_rpm, install_script, apt_index and checksums; the 0.0.x rpms keep the kind they were first sent with. The kind table names the package managers behind each installer count, since none of them reads stable*.yml.
2026-10-23 22:39:27 -07:00
DESKTOP-RTLN3BA\$punk
a416da8b9e fix(release-stats): refuse a redirect off the API's origin
urllib follows a redirect on its own and copies every header onto it,
the Authorization one included, so a 3xx to another host still carried
the token after next-page links were checked. The default opener now
follows a redirect only on the API's origin and raises
GitHubOriginError for any other, before a request goes there.
2026-10-22 13:45:31 -07:00
DESKTOP-RTLN3BA\$punk
7602d65c40 fix(release-stats): send the token only to the GitHub API's own origin
A next-page link off https://api.github.com now stops paging with an
error before any request, so the bearer token never leaves for another
host.
2026-10-22 13:36:46 -07:00
DESKTOP-RTLN3BA\$punk
c328df4655 fix(release-stats): key daily traffic on the day so reruns replace it
Each run sent yesterday's views and clones once, under a random event id,
so a rerun the same day doubled the daily sum and a missed run left a gap.
Send one github_traffic_day per whole day GitHub still holds, at that day's
midnight UTC with a uuid derived from the repository and the day, so PostHog
keeps one copy per day. The 14-day totals stay on github_traffic_snapshot.
2026-10-21 17:09:22 -07:00
DESKTOP-RTLN3BA\$punk
21e04825fe ci(release-stats): save GitHub asset counts and traffic daily
A daily job reads every release's per-asset download counts and, when
RELEASE_STATS_TOKEN has push access, the 14-day traffic GitHub otherwise
drops. It keeps the snapshot as a 90-day artifact and, with
POSTHOG_PROJECT_API_KEY set, sends personless events classified by which
client fetches each asset.
2026-10-21 16:19:33 -07:00