Skip to content

新宿・代々木など他路線レコードが最寄り駅の場合に大江戸線の方面が選べなくなる不具合をgroupIdフォールバックで修正 - #6362

Merged
TinyKitten merged 1 commit into
devfrom
claude/oedo-line-direction-fix-r5tf17
Jul 5, 2026

Conversation

@TinyKitten

Copy link
Copy Markdown
Member

概要

新宿駅・代々木駅などで都営大江戸線を選択した際、行先選択モーダルに方面ボタンが1つも表示されず方向が選べなくなる不具合を修正します。

#6349 (95de837) で useBounds の大江戸線分岐の現在駅位置特定が groupId 一致 → id 一致に変更されましたが、行先選択モーダルには選択した路線(大江戸線)の駅リストが渡される一方、現在駅は最寄り駅として検出されたレコードのままです。新宿・代々木ではこれが JR など他路線の駅レコードになるため、その id は大江戸線の駅リストに存在せず findIndex が -1 → bounds が [[], []](空)になっていました。都庁前のような大江戸線単独駅では id が一致するため発症しません。

変更の種類

  • バグ修正
  • 新機能
  • リファクタリング
  • ドキュメント
  • CI/CD
  • その他

変更内容

  • src/hooks/useBounds.ts: 大江戸線分岐で現在駅をまず id 一致で駅リストから探し(都庁前の外回り/内回り区別は維持)、見つからない場合のみ groupId 一致で大江戸線側の駅に読み替えるフォールバックを追加。
  • 同分岐内の自駅除外フィルタと「光が丘〜築地市場間では都庁前(内回り)を案内しない」判定も、読み替え後の大江戸線レコードの id を使うよう統一(他路線 id との数値比較になっていた潜在バグも解消)。
  • src/hooks/useBounds.test.tsx: JR新宿レコードが現在駅の場合に inbound(大門・両国)/ outbound(都庁前外回り・光が丘)が正しく返ることを検証する回帰テストを追加。

テスト

  • npm run lint が通ること
  • npm test が通ること
  • npm run typecheck が通ること

npm test は 185 スイート / 1959 件すべてパス(新規回帰テスト1件を含む)。

関連Issue

スクリーンショット(任意)


Generated by Claude Code

@github-actions github-actions Bot added the react label Jul 5, 2026
@coderabbitai

coderabbitai Bot commented Jul 5, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 42 minutes

Your organization has reached its usage spending cap. Adjust your spending cap in the billing tab.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 03fd22ca-ca6f-4afc-a134-81c86f381e81

📥 Commits

Reviewing files that changed from the base of the PR and between a6f6cba and 19bca57.

📒 Files selected for processing (2)
  • src/hooks/useBounds.test.tsx
  • src/hooks/useBounds.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch claude/oedo-line-direction-fix-r5tf17

Comment @coderabbitai help to get the list of available commands.

@TinyKitten TinyKitten self-assigned this Jul 5, 2026
@TinyKitten

Copy link
Copy Markdown
Member Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 5, 2026 •

Copy link
Copy Markdown
Contributor
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@TinyKitten
TinyKitten merged commit 4d11613 into dev Jul 5, 2026
6 checks passed
@TinyKitten
TinyKitten deleted the claude/oedo-line-direction-fix-r5tf17 branch July 5, 2026 12:09
@TinyKitten TinyKitten mentioned this pull request Jul 5, 2026
5 of 9 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants