feat: complete filter centralization pattern and document in CLAUDE.md
This commit is contained in:
@@ -88,19 +88,19 @@ Problem: Three separate filter implementations (`musicbrainz.FilterReleaseGroups
|
||||
- [x] Run tests - must pass before task 9
|
||||
|
||||
### Task 9: Remove SaveArtistSettings INSERT subquery inefficiency (minor)
|
||||
- [ ] Rewrite `SaveArtistSettings` to use two statements: INSERT with explicit values, then UPDATE on conflict (or use UPSERT with COALESCE for all columns including last_synced)
|
||||
- [ ] Ensure `last_synced` is preserved on update via `COALESCE(excluded.last_synced, artist_settings.last_synced)`
|
||||
- [ ] Write test verifying `last_synced` preserved on update
|
||||
- [ ] Run tests - must pass before task 10
|
||||
- [x] Rewrite `SaveArtistSettings` to use two statements: INSERT with explicit values, then UPDATE on conflict (or use UPSERT with COALESCE for all columns including last_synced)
|
||||
- [x] Ensure `last_synced` is preserved on update via `COALESCE(excluded.last_synced, artist_settings.last_synced)`
|
||||
- [x] Write test verifying `last_synced` preserved on update
|
||||
- [x] Run tests - must pass before task 10
|
||||
|
||||
### Task 10: Verify acceptance criteria and full test suite
|
||||
- [ ] Run `go test ./...` — all pass
|
||||
- [ ] Run `go vet ./...` — clean
|
||||
- [ ] Run `go build -o naviwatcher` — clean
|
||||
- [ ] Verify filter consistency: write an integration test that seeds DB with releases having SecondaryTypes=["EP"], toggles IgnoreSingles, and confirms the release is filtered regardless of cache state (cache-hit vs cache-miss vs scanner)
|
||||
- [ ] Update `config.yaml.example` if any new config fields added
|
||||
- [ ] Run tests - must pass
|
||||
- [x] Run `go test ./...` — all pass
|
||||
- [x] Run `go vet ./...` — clean
|
||||
- [x] Run `go build -o naviwatcher` — clean
|
||||
- [x] Verify filter consistency: write an integration test that seeds DB with releases having SecondaryTypes=["EP"], toggles IgnoreSingles, and confirms the release is filtered regardless of cache state (cache-hit vs cache-miss vs scanner)
|
||||
- [x] Update `config.yaml.example` if any new config fields added
|
||||
- [x] Run tests - must pass
|
||||
|
||||
### Task 11: Update documentation
|
||||
- [ ] Update README.md if any new behavior or config documented
|
||||
- [ ] Note the filter centralization pattern in CLAUDE.md if new pattern established
|
||||
- [x] Note the filter centralization pattern in CLAUDE.md if new pattern established
|
||||
Reference in New Issue
Block a user