[BUG] Repository health treats unmeasured signals as zero

オープン
#4,081 コメント 2 件 リアクション 0 件 担当者 1 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@Dhruvdesai793 がすでに取り組んでいます。

2026年12月3日 から。

評価

この issue はまだ評価されていません。

説明

bug needs-triage status:assigned
What happened?

On Dashboard → Repository Health, the API reports contributorCount: 0 and documentationScore: 0 for every repository. These are hard-coded in the route, then passed into the health score as if they were measured values. Both signals contribute up to 10 points, so every repo loses up to 20 points and is shown with zero contributors and a zero documentation score even when those signals are simply not collected.

Expected: calculate these signals from GitHub, or mark them unavailable and exclude them from scoring until they can be measured. Unknown data should not be reported as zero.

Source: the route returns both constants; the scorer includes both metrics and adds them to the total at lines 65–72.

Steps to reproduce
  1. Sign in and open Dashboard → Repository Health.
  2. Load any repository.
  3. Inspect GET /api/metrics/repo-health?days=30.
  4. The response reports contributorCount: 0 and documentationScore: 0 for every repository, and the score uses those values.
Where is it?

Dashboard overview

Where did you see it?

Local development

Browser and device

Not browser-specific; server-side API data.

Screenshots, console errors or logs

No screenshot or runtime log applies. Source-level proof is linked above. I did not run tests for this report to avoid using the shared checkout while another contributor is working. Existing test/repo-health-scoring.test.ts tests the scorer with supplied values; it does not exercise the API route or verify how missing signals are represented. A route test should confirm these values are calculated or treated as unavailable instead of serialized as zero.

Want to fix it?
  • I'd like to work on this. A maintainer will assign you; please don't start before that.
主要言語
TypeScript
スター
246
フォーク
436
平均マージ
9時間 33分
マージ済み PR(30日)
213

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

Priyanshu-byte-coder/devtrack のほかの issue

Priyanshu-byte-coder/devtrack の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。