Conversation
Add support for importing ICPC (International Collegiate Programming Contest) problems from Aizu Online Judge via the existing AojChallengesApiClient, covering both ICPC National Domestic Prelim and Asia Regional rounds. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Fix contestId format in plan.md examples (ICPCPrelim/ICPCRegional prefix) - Add CodeRabbit Findings section with two rounds of review notes - Add ICPC REGIONAL test case in clients.test.ts - Add comment clarifying ICPC round constraints in record_requests.ts Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughAOJ の ICPC(Prelim/Regional)を import 対象に追加するため、DB enum、型、クライアント、import ソース、分類・表示ロジック、タスク生成、および対応テストを追加しました。 ChangesAOJ ICPC Contest Support
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/lib/clients/aizu_online_judge/types.ts`:
- Around line 36-40: 現在の ChallengeRoundMap と ChallengeContestType の定義は
contestType と round の相関を強制しておらず、例えば { contestType: 'ICPC', round: 'FINAL' }
のような不正な組合せが通ってしまいます。ChallengeRoundMap と関連型(PckRound, JagRound,
IcpcRound)をそのまま使うのではなく、contestType を識別子にした判別共用体(例: { contestType: 'PCK'; round:
PckRound } | { contestType: 'JAG'; round: JagRound } | { contestType: 'ICPC';
round: IcpcRound })に置き換え、既存の参照(ChallengeRoundMap や ChallengeContestType
を用いる箇所)をこの新しい判別共用体型に差し替えて相関を強制してください。
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 89d508aa-e6c3-4bc3-86e1-7cf3705a9184
📒 Files selected for processing (17)
prisma/migrations/20260520080410_add_aoj_icpc_to_contest_type/migration.sqlprisma/schema.prismasrc/lib/clients/aizu_online_judge/clients.test.tssrc/lib/clients/aizu_online_judge/types.tssrc/lib/clients/fixtures/aizu_online_judge/challenges/icpc_prelim/contests.jsonsrc/lib/clients/fixtures/aizu_online_judge/challenges/icpc_regional/contests.jsonsrc/lib/clients/fixtures/record_requests.tssrc/lib/clients/index.tssrc/lib/types/contest.tssrc/lib/utils/contest.tssrc/lib/utils/task.tssrc/test/lib/utils/contest.test.tssrc/test/lib/utils/task.test.tssrc/test/lib/utils/test_cases/contest_name_and_task_index.tssrc/test/lib/utils/test_cases/contest_name_labels.tssrc/test/lib/utils/test_cases/contest_type.tssrc/test/lib/utils/test_cases/task_url.ts
…ChallengeContestType/ChallengeRoundMap Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
close #3562
Summary by CodeRabbit
新機能
テスト