Repository navigation
feat: allow reclassifying commit headlines in batches - #1438
Conversation
|
Caution Review failedThe pull request is closed. Walkthrough
Merge Risk:
|
There was a problem hiding this comment.
🟡 Changes recommended
Unconditional detachment recreates retained headline links with fresh timestamps, incorrectly extending their fourteen-day pruning window despite no new linked commits.
1 open issue
What changed in this PR
Adds opt-in batch reclassification to the headline backfill command while preserving its default incremental behavior.
Changes:
- Introduces
--reclassifyand passes it through the headline-processing jobs. - Replaces eligible commits’ headline assignments transactionally and clears affected recaps.
- Adds replacement, provider-failure, and legacy queued-payload regression coverage.
| File | Description |
|---|---|
tests/Unit/Jobs/ProcessCommitHeadlinesTest.php |
Tests processing of legacy queued batches. |
tests/Unit/Jobs/LinkCommitHeadlinesTest.php |
Tests idempotency with current and legacy payloads. |
tests/Feature/Commands/LinkCommitHeadlinesTest.php |
Covers batch replacement and preservation on provider failure. |
app/Jobs/ProcessCommitHeadlines.php |
Includes classified commits when requested and forwards the flag. |
app/Jobs/LinkCommitHeadlines.php |
Passes the flag to the action with a legacy-safe default. |
app/Console/Commands/LinkCommitHeadlinesCommand.php |
Adds the flag and adjusts batch selection. |
app/Actions/UpdateCommitHeadlines.php |
Replaces assignments and clears recaps within the transaction. |
Review effort: Balanced

Summary
The headline backfill command skips commits once they have been classified, so it cannot revisit existing results after classification changes. Add an opt-in
--reclassifyflag:Without the flag, incremental processing stays unchanged.
Changes
Validation
All checks passed locally on the final revision:
vendor/bin/pint --dirty --format agentcomposer test:lint— passed; existing warnings in unchanged frontend files remain.composer test:types— passed.composer test:type-coverage— 100%.bun run test:unit— 223 tests passed.php artisan test --compact tests/Feature/Commands/LinkCommitHeadlinesTest.php tests/Unit/Actions/UpdateCommitHeadlinesTest.php tests/Unit/Jobs/ProcessCommitHeadlinesTest.php tests/Unit/Jobs/LinkCommitHeadlinesTest.php— 52 tests, 199 assertions passed.php -d memory_limit=-1 vendor/bin/pest --parallel --ci --coverage --exactly=100.0 --passthru-php="'-d' 'memory_limit=-1'"— 5,499 tests, 29,796 assertions passed; 100% coverage.git diff --check— passed.Visual and device verification are inapplicable: no UI or mobile interactions changed. No live AI-provider or production processing was performed.
Independent review
Independent read-only reviewer: PASS, with no unresolved blockers, for base 3c79473a and head 77e13c7d.
Review covered the full eight-file diff, correctness, regressions, architecture, transaction/concurrency behavior, and test value. An initial queued-payload compatibility finding was fixed and re-reviewed. The reviewer inspected code and test evidence rather than rerunning the suite; the implementer completed the final full coverage run after review without further code changes. Visual review is inapplicable.
Limitations
The minor review finding about pivot creation timestamps is deliberately unchanged; this update addresses only CodeRabbit’s major recap-invalidation finding.
The flag revisits all eligible commits, not a selected date range or batch identifier. Reclassification reuses the existing shared headline pool and can make AI-provider requests for every eligible commit. Successful per-commit updates are retained if a later commit or batch fails. Hosted CI results are separate from the local validation above.
Summary by CodeRabbit