mirror of
https://github.com/borgbackup/borg.git
synced 2026-10-12 02:11:36 +00:00
fame.py: order contributors deterministically, drop the push trigger
The workflow no longer runs on pushes to FAME.md. The "Lines" column is blame of the current checkout and master sees dozens of commits a week, so merging one of these pull requests immediately produced the next one: #10008 was merged at 10:26:09 and #10009 opened 37 seconds later. Both files are written by the same run and cannot drift apart, so the weekly run plus manual dispatch is enough. git-fame also leaves people with the same commit count in its own order, which is stable for one checkout but not across checkouts, so tied ranks kept shuffling and added diff noise. Sort by commits, then surviving lines, then name. The next run will apply that order to FAME.md.
This commit is contained in:
@@ -125,6 +125,10 @@ def collect():
|
||||
)
|
||||
fame = json.loads(out)
|
||||
rows = [(name, commits, loc, files) for name, loc, commits, files, *_percentages in fame["data"]]
|
||||
# git-fame leaves people with the same commit count in its own order, which
|
||||
# is stable for a given checkout but not across checkouts, so equal ranks
|
||||
# would shuffle from one run to the next. Break the tie ourselves.
|
||||
rows.sort(key=lambda row: (-row[1], -row[2], row[0]))
|
||||
return rows, fame["total"]
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user