Skip to content

報告者サマリ: 報告者 のリンク先が間違っている問題を修正#18

Merged
max747 merged 5 commits into
mainfrom
feat/fix-reporters-link
May 9, 2026
Merged

報告者サマリ: 報告者 のリンク先が間違っている問題を修正#18
max747 merged 5 commits into
mainfrom
feat/fix-reporters-link

Conversation

@max747
Copy link
Copy Markdown
Member

@max747 max747 commented May 9, 2026

No description provided.

@max747 max747 self-assigned this May 9, 2026
@max747 max747 added the bug Something isn't working label May 9, 2026
@max747 max747 requested a review from Copilot May 9, 2026 11:08
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

報告者サマリ画面の「報告者」列リンクが誤ったリンク先(X ID ベース)になっていた問題を、Harvest の reporter_id(owner ID)を使うように修正するPRです。フロント側の型定義・集計処理・表示コンポーネント、および集計Lambdaの出力を揃えて reporterId を新しく受け渡します。

Changes:

  • Report / ReporterRowreporterId を追加し、集計・表示に渡す
  • 報告者サマリの「報告者」リンクを /owners/{reporterId}/reports に変更(X ID は x.com へのリンクのまま)
  • 集計Lambdaで reporter_idreporterId として出力するよう拡張

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
viewer/src/types.ts ReportreporterId を追加し、フロントのデータ型を拡張
viewer/src/reportTableUtils.test.ts Report 生成fixtureに reporterId を追加
viewer/src/reporterSummaryUtils.ts 集計行 ReporterRowreporterId を追加し、集計結果に載せる
viewer/src/reporterSummaryUtils.test.ts reporterId を含むfixtureに更新
viewer/src/components/ReporterSummary.tsx 報告者リンク先を owner ID(reporterId)ベースに修正し、リンク生成を共通化
viewer/src/aggregate.test.ts Report fixtureに reporterId を追加
lambda/aggregator/handler.py Harvest入力の reporter_id を中間JSONの reporterId として出力
Comments suppressed due to low confidence (1)

viewer/src/reporterSummaryUtils.ts:55

  • aggregateReporters only sets reporterId when creating a new row. If the first report for a given reporter name has an empty reporterId (or is missing it) and a later report has a non-empty reporterId, the aggregated row will keep "", so the reporter link will stay non-clickable even though an ID exists. Consider updating entry.reporterId (and potentially entry.xId) when an existing entry is found and the stored value is empty but the current report provides one.
      const name = getReporterName(r);
      const entry = map.get(name) ?? {
        reporter: name,
        reporterId: r.reporterId || "",
        xId: r.reporter || "",
        reportCount: 0,
        totalRuns: 0,
        details: [],
      };

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 18 to 24
quest: { questId, name: questName, level: "90", ap: 40 },
lastUpdated: "2026-01-01T00:00:00Z",
reports: reports.map((r) => ({
...r,
reporterId: r.reporterId ?? "",
timestamp: "2026-01-01T00:00:00Z",
note: "",
max747 and others added 4 commits May 9, 2026 20:25
最初の報告に reporterId が空でも、後の報告に有効な値があれば更新する。
xId も同様に補完する。

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
- reporterId が ReporterRow に正しく伝わることを検証
- 最初の報告が空 reporterId でも後続報告の値で補完されることを検証

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
@max747 max747 merged commit 987c569 into main May 9, 2026
1 check passed
@max747 max747 deleted the feat/fix-reporters-link branch May 9, 2026 11:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants