Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 6 additions & 13 deletions .github/workflows/daily-update.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@
name: daily-update

# Each run also stores its result under rankings/<date>/<slot>/ (history) and latest/.
# Runs at Beijing 00:00 and America/Los_Angeles 00:00 every day.
# Beijing (UTC+8, no DST): 16:00 UTC -> '0 16 * * *'
# Los Angeles midnight: 07:00 UTC in PDT, 08:00 UTC in PST -> '0 7 * * *' and '0 8 * * *'
# GitHub cron is UTC-only, so the two LA entries both fire and tools/schedule_guard.py lets only the
# Runs once a day at America/Los_Angeles 00:00 (follows DST).
# Los Angeles midnight: 07:00 UTC in PDT, 08:00 UTC in PST -> '0 7 * * *' and '0 8 * * *'
# GitHub cron is UTC-only, so both entries fire and tools/schedule_guard.py lets only the
# one that is actually 00:xx in America/Los_Angeles continue; the other one skips.
# Scheduled workflows run from the default branch only. Runs can start a few minutes late.
# If Actions is unavailable for the account, use tools/local_daily.sh (see docs/DAILY_UPDATE.md).
on:
schedule:
- cron: '0 16 * * *'
- cron: '0 7 * * *'
- cron: '0 8 * * *'
workflow_dispatch:
Expand All @@ -34,15 +32,10 @@ jobs:
id: gate
env:
EVENT: ${{ github.event_name }}
CRON: ${{ github.event.schedule }}
run: |
# Beijing slot and manual runs always proceed. The two LA slots proceed only at LA midnight.
# Output "slot" names the history folder: cn -> rankings/<date>/cn-0000, pt -> pt-0000,
# auto (manual dispatch) -> cn/pt if the clock happens to be at a slot, else manual-HHMM.
if [ "$EVENT" = "schedule" ] && [ "$CRON" = "0 16 * * *" ]; then
echo "run=true" >> "$GITHUB_OUTPUT"
echo "slot=cn" >> "$GITHUB_OUTPUT"
elif [ "$EVENT" = "schedule" ]; then
# Scheduled runs proceed only at Los Angeles midnight (history folder pt-0000).
# Manual dispatch always proceeds: auto -> pt if the clock is at LA midnight, else manual-HHMM.
if [ "$EVENT" = "schedule" ]; then
if python3 tools/schedule_guard.py --tz America/Los_Angeles --hour 0; then
echo "run=true" >> "$GITHUB_OUTPUT"
echo "slot=pt" >> "$GITHUB_OUTPUT"
Expand Down
27 changes: 13 additions & 14 deletions CURRENT_PLAN.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,39 +2,38 @@

## Plan ID

PLAN-004
PLAN-005

## Goal

Stop the recurring daily-update failures at the root: the scheduled run must validate the data it generated (hard errors fail, GitHub API timing drift warns) instead of running the unit-test suite against live data, and must survive rate limits and a moving `main`.
Production ranking updates run once a day at America/Los_Angeles midnight; public README copy only says it updates daily, with no cron clocks or dual Beijing+PT schedule.

## In Scope

- `tools/data_checks.py`, `tools/verify.py --daily`, `.github/workflows/daily-update.yml`, `tools/local_daily.sh`
- `tools/update_stars.py` API retry/backoff, `tools/risers_core.py` hard limit for history drift
- Tests in `tests/test_daily_robustness.py`; docs in `docs/DAILY_UPDATE.md` and governance files
- `.github/workflows/daily-update.yml`, `tools/schedule_guard.py` wiring, `docs/launchd/`, `tools/local_daily.sh`, `tools/mac_i18n_cron.sh`, `tools/com.jammyfu.risers-i18n.plist`
- Public copy in `tools/i18n.py` (stamp / a3 / schedule / tagline), `docs/FAQ.md`, `docs/FACTS.md`; operator details in `docs/DAILY_UPDATE.md`
- Tests in `tests/test_schedule.py`, `tests/test_spam.py`, `tests/test_repo.py`; governance files

## Out of Scope

- Ranking logic, README copy, cron times, secrets, merging to `main`
- Ranking logic, star-data fetch, translation pipeline, deleting historical `cn-0000` snapshots, merging to `main`

## Tasks

- [x] Group the failed runs by cause (41122642510, 41235403615)
- [x] Add `tools/data_checks.py` with error and warning severities and `verify.py --daily`
- [x] Wire the workflow and `local_daily.sh` to `--daily`; unit tests stay in `ci.yml`
- [x] Retry 429 / rate-limited 403 / 5xx / network errors; retry the push after rebasing onto `main`
- [x] Regression tests for all of the above
- [ ] Owner reviews the PR; merge only with approval
- [x] Drop the Beijing cron from `daily-update.yml`; keep the two LA UTC crons with `schedule_guard.py`, slot `pt`
- [x] Align local fallback (launchd / cron docs / i18n Mac job) to once daily after US midnight
- [x] Change README / HOW_IT_WORKS strings so readers only see daily update / 每天更新, not clocks
- [x] Update FAQ, FACTS, operator docs and tests that pinned twice-daily / Beijing 00:00
- [x] Re-render generated pages; `python3 tools/verify.py` and `python3 tools/next_plan.py --check` pass
- [x] Open a PR; do not merge

## Verification

- `python3 tools/verify.py`
- `python3 tools/verify.py --daily`
- `python3 tools/next_plan.py --check`

## Next Candidates

- After merge, confirm the next scheduled `daily-update` run commits data
- After merge, confirm the next scheduled `daily-update` run writes `rankings/<date>/pt-0000/`
- Thin Developer Tools / Design / Data new-repo boards: see `TODO_BACKLOG.md`
- Acceleration column (this week vs the week before)
6 changes: 3 additions & 3 deletions MASTER_PLAN.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Goal

A trustworthy ranking of fast-rising GitHub repositories by stars gained per day, grouped by category (AI first), refreshed twice a day from the GitHub API and readable in five languages.
A trustworthy ranking of fast-rising GitHub repositories by stars gained per day, grouped by category (AI first), refreshed daily from the GitHub API and readable in five languages.

## Current phase

Expand All @@ -15,7 +15,7 @@ Phase 4: harness and upkeep (Phases 1-3 are done and merged).

### Phase 2: Growth data and automation (done)
- stars/day for 7/30/365 days from `stargazers/history`
- Daily update (Actions + local fallback) at Beijing 00:00 and Los Angeles 00:00, per-slot history, `latest/`
- Daily update (Actions + local fallback) at America/Los_Angeles 00:00, per-slot history, `latest/`
- Top-20 boards, 7-day newcomers board

### Phase 3: Categories, i18n pipeline, discovery (done)
Expand All @@ -30,7 +30,7 @@ Phase 4: harness and upkeep (Phases 1-3 are done and merged).
## Definition of done for a phase

- `python3 tools/verify.py` passes; data in `data/stats.json` came from a real run
- A daily update has run unattended at both the Beijing and Los Angeles slots
- A daily update has run unattended at the Los Angeles slot

## Questions for next review

Expand Down
2 changes: 1 addition & 1 deletion PROJECT_BRIEF.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Open-source projects ranked by star growth speed (stars/day), grouped by categor

## Why

Total-star lists let old projects stay on top; newly rising projects get buried. All numbers are pulled from the GitHub API daily at Beijing and Los Angeles midnight.
Total-star lists let old projects stay on top; newly rising projects get buried. All numbers are pulled from the GitHub API daily.

## First goals

Expand Down
6 changes: 3 additions & 3 deletions README.ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@

[![MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE) [![CI](https://github.com/jammyfu/github-risers/actions/workflows/ci.yml/badge.svg)](https://github.com/jammyfu/github-risers/actions/workflows/ci.yml) [![updated](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fraw.githubusercontent.com%2Fjammyfu%2Fgithub-risers%2Fmain%2Fdata%2Fstats.json&query=%24.today_utc&label=updated&color=brightgreen)](latest/rankings.ja.md)

総スター数ではなく、1 日あたりに増えたスター数で GitHub リポジトリを並べます。AI が先頭で、開発者ツール、セキュリティ、Web / フロントエンド、インフラ、デザイン / クリエイティブ、データが続きます。1 日 2 回更新。
総スター数ではなく、1 日あたりに増えたスター数で GitHub リポジトリを並べます。AI が先頭で、開発者ツール、セキュリティ、Web / フロントエンド、インフラ、デザイン / クリエイティブ、データが続きます。毎日更新。

データ取得 2026-11-04 21:42(UTC)。1 日 2 回:北京時間 0 時(UTC+8)、ロサンゼルス時間 0 時(America/Los_Angeles)。
データ取得 2026-11-04 21:42(UTC)。毎日更新。

[ウェブサイト](https://jammyfu.github.io/github-risers/) · [仕組み](docs/HOW_IT_WORKS.ja.md) · [ファクト](docs/FACTS.md) · [履歴](rankings/README.ja.md) · [最新](latest/rankings.ja.md)

Expand Down Expand Up @@ -40,7 +40,7 @@ GitHub Trending は GitHub 公式のページです。GitHub Risers は独立し

### 更新は何回?

1 日 2 回、北京時間 0 時とロサンゼルス時間 0 時です。実行のたびに保存します。 [詳しく見る](docs/FAQ.md#how-often-is-it-updated)
毎日更新します。実行のたびに保存します。 [詳しく見る](docs/FAQ.md#how-often-is-it-updated)

### 数値はどう出す?

Expand Down
6 changes: 3 additions & 3 deletions README.ko.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@

[![MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE) [![CI](https://github.com/jammyfu/github-risers/actions/workflows/ci.yml/badge.svg)](https://github.com/jammyfu/github-risers/actions/workflows/ci.yml) [![updated](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fraw.githubusercontent.com%2Fjammyfu%2Fgithub-risers%2Fmain%2Fdata%2Fstats.json&query=%24.today_utc&label=updated&color=brightgreen)](latest/rankings.ko.md)

총 스타 수가 아니라 하루에 늘어난 스타 수로 GitHub 저장소를 줄 세웁니다. AI가 맨 앞이고 개발자 도구, 보안, Web / 프론트엔드, 인프라, 디자인 / 크리에이티브, 데이터가 뒤따릅니다. 하루 두 번 갱신합니다.
총 스타 수가 아니라 하루에 늘어난 스타 수로 GitHub 저장소를 줄 세웁니다. AI가 맨 앞이고 개발자 도구, 보안, Web / 프론트엔드, 인프라, 디자인 / 크리에이티브, 데이터가 뒤따릅니다. 매일 갱신합니다.

데이터 시각 2026-11-04 21:42(UTC). 하루 두 번: 베이징 0시(UTC+8), 로스앤젤레스 0시(America/Los_Angeles).
데이터 시각 2026-11-04 21:42(UTC). 매일 갱신합니다.

[웹사이트](https://jammyfu.github.io/github-risers/) · [작동 방식](docs/HOW_IT_WORKS.ko.md) · [팩트](docs/FACTS.md) · [지난 랭킹](rankings/README.ko.md) · [최신](latest/rankings.ko.md)

Expand Down Expand Up @@ -40,7 +40,7 @@ GitHub Trending은 GitHub 공식 페이지입니다. GitHub Risers는 독립적

### 얼마나 자주 갱신하나요?

하루 두 번, 베이징 시간 0시와 로스앤젤레스 시간 0시입니다. 실행할 때마다 보관합니다. [더 보기](docs/FAQ.md#how-often-is-it-updated)
매일 갱신합니다. 실행할 때마다 보관합니다. [더 보기](docs/FAQ.md#how-often-is-it-updated)

### 숫자는 어떻게 계산하나요?

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

Trending GitHub repos ranked by star growth (stars gained per day), not total stars: AI first, then developer tools, security, web, infrastructure, design and data.

Data from 2026-11-04 21:42 UTC. Twice a day: 00:00 Beijing (UTC+8) and 00:00 Los Angeles (America/Los_Angeles).
Data from 2026-11-04 21:42 UTC. Updated daily.

[Website](https://jammyfu.github.io/github-risers/) · [How it works](docs/HOW_IT_WORKS.md) · [Facts](docs/FACTS.md) · [History](rankings/README.md) · [Latest](latest/rankings.md)

Expand Down Expand Up @@ -40,7 +40,7 @@ GitHub Trending is GitHub's own page. GitHub Risers is an independent open-sourc

### How often is it updated?

Twice a day, at 00:00 Beijing time and 00:00 Los Angeles time. Every run is archived. [Read more](docs/FAQ.md#how-often-is-it-updated)
Updated daily. Every run is archived. [Read more](docs/FAQ.md#how-often-is-it-updated)

### How is the data computed?

Expand Down
6 changes: 3 additions & 3 deletions README.zh-Hans.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@

[![MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE) [![CI](https://github.com/jammyfu/github-risers/actions/workflows/ci.yml/badge.svg)](https://github.com/jammyfu/github-risers/actions/workflows/ci.yml) [![updated](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fraw.githubusercontent.com%2Fjammyfu%2Fgithub-risers%2Fmain%2Fdata%2Fstats.json&query=%24.today_utc&label=updated&color=brightgreen)](latest/rankings.zh-Hans.md)

按每天新增星标(而不是总星标)给 GitHub 仓库排名:AI 在前,其后是开发者工具、安全、Web / 前端、基础设施、设计 / 创意和数据;每天更新两次。
按每天新增星标(而不是总星标)给 GitHub 仓库排名:AI 在前,其后是开发者工具、安全、Web / 前端、基础设施、设计 / 创意和数据;每天更新。

数据取自 2026-11-04 21:42(UTC)。每天两次:北京时间 0 点(UTC+8)、洛杉矶时间 0 点(America/Los_Angeles)。
数据取自 2026-11-04 21:42(UTC)。每天更新。

[网站](https://jammyfu.github.io/github-risers/) · [运作方式](docs/HOW_IT_WORKS.zh-Hans.md) · [事实速查](docs/FACTS.md) · [历史榜单](rankings/README.zh-Hans.md) · [最新快照](latest/rankings.zh-Hans.md)

Expand Down Expand Up @@ -40,7 +40,7 @@ GitHub Trending 是 GitHub 官方页面;GitHub 涨星榜是独立的开源项

### 多久更新一次?

每天两次,北京时间 0 点和洛杉矶时间 0 点;每次运行都会存档。 [了解更多](docs/FAQ.md#how-often-is-it-updated)
每天更新;每次运行都会存档。 [了解更多](docs/FAQ.md#how-often-is-it-updated)

### 数据怎么算?

Expand Down
6 changes: 3 additions & 3 deletions README.zh-Hant.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@

[![MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE) [![CI](https://github.com/jammyfu/github-risers/actions/workflows/ci.yml/badge.svg)](https://github.com/jammyfu/github-risers/actions/workflows/ci.yml) [![updated](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fraw.githubusercontent.com%2Fjammyfu%2Fgithub-risers%2Fmain%2Fdata%2Fstats.json&query=%24.today_utc&label=updated&color=brightgreen)](latest/rankings.zh-Hant.md)

依每天新增星號(而不是總星號)替 GitHub 儲存庫排名:AI 在前,接著是開發者工具、資安、Web / 前端、基礎建設、設計 / 創意與資料;每天更新兩次。
依每天新增星號(而不是總星號)替 GitHub 儲存庫排名:AI 在前,接著是開發者工具、資安、Web / 前端、基礎建設、設計 / 創意與資料;每天更新。

資料取自 2026-11-04 21:42(UTC)。每天兩次:北京時間 0 點(UTC+8)、洛杉磯時間 0 點(America/Los_Angeles)。
資料取自 2026-11-04 21:42(UTC)。每天更新。

[網站](https://jammyfu.github.io/github-risers/) · [運作方式](docs/HOW_IT_WORKS.zh-Hant.md) · [事實速查](docs/FACTS.md) · [歷史榜單](rankings/README.zh-Hant.md) · [最新快照](latest/rankings.zh-Hant.md)

Expand Down Expand Up @@ -40,7 +40,7 @@ GitHub Trending 是 GitHub 官方頁面;GitHub 漲星榜是獨立的開源專

### 多久更新一次?

每天兩次,北京時間 0 點和洛杉磯時間 0 點;每次執行都會存檔。 [了解更多](docs/FAQ.md#how-often-is-it-updated)
每天更新;每次執行都會存檔。 [了解更多](docs/FAQ.md#how-often-is-it-updated)

### 資料怎麼算?

Expand Down
3 changes: 1 addition & 2 deletions TODO_BACKLOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@

## Now

- [ ] After the daily-update reliability PR (PLAN-004) is merged, confirm the next scheduled `daily-update` run commits data (Verify must only fail on real data errors)
- [ ] Confirm the first unattended cron runs after the merge: `cn-0000` (Beijing) and `pt-0000` (Los Angeles) folders appear under `rankings/<date>/` (`gh run list --workflow daily-update.yml`)
- [ ] After the once-daily US schedule PR (PLAN-005) is merged, confirm the next scheduled `daily-update` run writes `rankings/<date>/pt-0000/` (`gh run list --workflow daily-update.yml`)
- [ ] Developer Tools new-repo board: 15 of 20 entries were flagged ⚠ in the last run because star-farmed repos use `cli` / `developer-tools`; decide whether to add a quality signal (owner call)
- [ ] Design and Data new-repo boards are thin (0-2 entries): widen with specific topics only (no generic ones; `tests/test_spam.py` guards that)

Expand Down
Loading
Loading