Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 31 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,14 +184,18 @@ $env:ALBUM_COUNT=100000; pnpm db:seed:large

**Both commands reset the catalog and remove associated tracks, reviews and crate items.** If a large seed is interrupted, rerun it to reset and regenerate the catalog.

### Real album catalog (#63)

The committed snapshot at `server/data/musicbrainz-albums.json` contains 500
MusicBrainz release groups, selected across nine normalized genres and release
decades from the 1960s through the 2020s. A release group represents an album
across its editions, so the snapshot does not add every reissue as a separate
album. The import runs locally from this file; the app does not call MusicBrainz
at runtime. Reimporting is safe and keeps existing album IDs and user-generated
### Real album catalog (#63, #105)

The committed snapshot at `server/data/musicbrainz-albums.json` contains 2,000
MusicBrainz release groups, selected across 11 normalized genres, 60 artist
countries and release decades from the 1950s through the 2020s. It includes 49
curated familiar albums, listed in
[`server/data/familiar-musicbrainz-albums.json`](server/data/familiar-musicbrainz-albums.json),
as well as a wider catalog for exploring the filters. A release group represents
an album across its editions, so the snapshot does not add every reissue as a
separate album.
The import runs locally from this file; the app does not call MusicBrainz at
runtime. Reimporting is safe and keeps existing album IDs and user-generated
reviews and crate items. Matching hand-seeded albums are reused by title and
primary artist.

Expand All @@ -208,14 +212,17 @@ pnpm db:fetch:musicbrainz
pnpm db:import:musicbrainz
```

The fetch script identifies itself with a User-Agent and spaces requests to
respect MusicBrainz's rate limit. It looks up country for each unique credited
artist and stores the MusicBrainz artist ID with the country code. Artists with
no country remain unassigned. Review the generated snapshot before
committing it. MusicBrainz core data is CC0 1.0; genre associations are
user-contributed tag data under CC BY-NC-SA 3.0. The snapshot retains that
distinction and the MusicBrainz release-group IDs for attribution and
reproducibility. See [MusicBrainz Data License](https://musicbrainz.org/doc/About/Data_License)
The familiar album targets are listed in
[`server/data/familiar-musicbrainz-albums.json`](server/data/familiar-musicbrainz-albums.json)
and resolved to release-group IDs during the fetch. The script identifies itself
with a User-Agent, spaces requests to respect MusicBrainz's rate limit, and looks
up artist countries in batches by MBID. Countries from the previous snapshot and
track lists are reused when available. Artists with no country remain
unassigned. Review the generated snapshot before committing it. MusicBrainz core
data is CC0 1.0; genre associations are user-contributed tag data under CC
BY-NC-SA 3.0. The snapshot retains that distinction and the MusicBrainz
release-group IDs for attribution and reproducibility. See
[MusicBrainz Data License](https://musicbrainz.org/doc/About/Data_License)
and [MusicBrainz API](https://musicbrainz.org/doc/MusicBrainz_API).

Album artwork is loaded externally from Cover Art Archive using the existing
Expand All @@ -230,10 +237,12 @@ scores, artwork audit findings and the JavaScript bundle budget verified for #23

### Catalog quality (#64)

We checked the snapshot and the imported catalog (516 albums with the sample
seed) for duplicates, missing metadata, artist and genre links and track order.
Every sort was paged through the whole result set without gaps or repeats, and
the facet counts match the filtered totals. Fixes from the check:
The original #64 quality check covered the initial 500-album snapshot and the
imported catalog with the 16-album sample seed (516 albums total). It checked
duplicates, missing metadata, artist and genre links, track order, full-result
pagination and facet counts. The expanded #105 snapshot is checked for unique
release-group IDs, familiar album coverage and filter-data variety before it is
committed. Fixes from the original catalog check:

- MusicBrainz writes hyphens as U+2010, so "esa-pekka" or "switched-on" found
nothing. The importer now stores ASCII hyphens.
Expand All @@ -245,9 +254,9 @@ the facet counts match the filtered totals. Fixes from the check:

Remaining limitations:

- Only 50 of the 500 albums have a track list, taken from one official release
- Only 100 of the 2,000 albums have a track list, taken from one official release
of the release group. The album page says when there are no tracks.
- Seven albums have no release year. They sort last and have no decade facet.
- 21 albums have no release year. They sort last and have no decade facet.
- Search is not accent-insensitive: "beyonce" does not find "Beyoncé", and
names in other scripts (for example Mulatu Astatke as ሙላቱ አስታጥቄ) only match
as written.
Expand Down
1 change: 1 addition & 0 deletions docs/AI-USAGE.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ the part that matters most.
| 2026-11-20 | erikhfj | Antigravity | #100, review author privacy: removed `User.id` from `schema.graphql` and the `AlbumDetail` query, replaced `Listener <uuid-prefix>` with deterministic SHA-256 music pseudonyms in `server/src/userIdentity.ts` (including read-time sanitization of legacy labels in `Review.user`), added `User` cache merge policy, and updated schema/unit/client tests and `docs/architecture.md`. Verified with `pnpm codegen`, `pnpm format:check`, `pnpm lint`, `pnpm typecheck`, `pnpm test`, and `pnpm build`. |
| 2026-11-20 | erikhfj | Antigravity | #103, search history error visibility and focus: moved the search history error message and Retry button inside the open `RecentSearches` dropdown so closed-state errors cannot overlap page content, returned retry success from `useSearchHistory`, restored focus to the search input after a successful retry in `SearchForm`, and added unit/integration tests. Verified with `pnpm format:check && pnpm lint && pnpm typecheck && pnpm test && pnpm build`. |
| 2026-11-20 | erikhfj | Antigravity | #95, loading skeleton cards: rendered 8 `aria-hidden="true"` placeholder cards inside `.album-grid--loading` while `ResultsLayout` is loading so the layout does not collapse, styled with plain CSS and `prefers-reduced-motion` support, kept `role="status"` and `aria-busy` unchanged, and added a loading-state test in `App.test.tsx`. Verified with `pnpm format:check && pnpm lint && pnpm typecheck && pnpm test && pnpm build`. |
| 2026-11-20 | robertky | Codex (ChatGPT) | #105: assisted with expanding the MusicBrainz snapshot to 2,000 albums, selecting familiar album targets, paginating source searches, batching artist-country lookups and updating catalog checks and documentation. Robert requested the expansion following instructor feedback; validation results are recorded in the PR. |
| 2026-11-22 | evenkkl | Claude | #96, skip count and facet queries on Load more: Claude made the search aggregates lazy `AlbumConnection` field resolvers, added a `SearchAlbumsPage` query for Load more, kept page one's count and facets in the Apollo merge, and added server and client tests. Verified with lint, typecheck, the test suites and the PostgreSQL tests on PGlite. |
| 2026-11-22 | erikhfj | Antigravity | #117, stabilized `ReviewForm.test.tsx`: traced the intermittent CI failure (run `88055`) to `findByRole('status')` resolving via `MutationObserver` before React's passive `useEffect` focused `statusRef`, and wrapped the status focus assertions in `waitFor`. Verified with 10 consecutive test runs plus `pnpm format:check && pnpm lint && pnpm typecheck && pnpm test`. |
| 2026-11-22 | erikhfj | Antigravity | #107, documented the team's AI task delegation, verification, and review workflow in `docs/AI-USAGE.md`, reflecting actual practices across all four contributors and complementing #97's prompt-context section. Verified with `pnpm format:check && pnpm lint && pnpm typecheck && pnpm test`. |
Expand Down
59 changes: 59 additions & 0 deletions server/data/familiar-musicbrainz-albums.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
[
{ "title": "Abbey Road", "artist": "The Beatles", "genre": "Rock" },
{ "title": "The Dark Side of the Moon", "artist": "Pink Floyd", "genre": "Rock" },
{ "title": "Rumours", "artist": "Fleetwood Mac", "genre": "Rock" },
{ "title": "Led Zeppelin IV", "artist": "Led Zeppelin", "genre": "Rock" },
{ "title": "Nevermind", "artist": "Nirvana", "genre": "Rock" },
{ "title": "Back in Black", "artist": "AC/DC", "genre": "Rock" },
{ "title": "The Joshua Tree", "artist": "U2", "genre": "Rock" },
{ "title": "Born to Run", "artist": "Bruce Springsteen", "genre": "Rock" },
{ "title": "A Night at the Opera", "artist": "Queen", "genre": "Rock" },
{
"title": "The Rise and Fall of Ziggy Stardust and the Spiders from Mars",
"artist": "David Bowie",
"genre": "Rock"
},
{ "title": "Thriller", "artist": "Michael Jackson", "genre": "Pop" },
{ "title": "Purple Rain", "artist": "Prince", "genre": "Pop" },
{ "title": "1989", "artist": "Taylor Swift", "genre": "Pop" },
{ "title": "Bad", "artist": "Michael Jackson", "genre": "Pop" },
{ "title": "The Fame", "artist": "Lady Gaga", "genre": "Pop" },
{ "title": "Hounds of Love", "artist": "Kate Bush", "genre": "Pop" },
{ "title": "21", "artist": "Adele", "genre": "Pop" },
{ "title": "Tapestry", "artist": "Carole King", "genre": "Pop" },
{ "title": "What's Going On", "artist": "Marvin Gaye", "genre": "Soul" },
{ "title": "Songs in the Key of Life", "artist": "Stevie Wonder", "genre": "Soul" },
{ "title": "Back to Black", "artist": "Amy Winehouse", "genre": "Soul" },
{ "title": "Kind of Blue", "artist": "Miles Davis", "genre": "Jazz" },
{ "title": "Time Out", "artist": "The Dave Brubeck Quartet", "genre": "Jazz" },
{ "title": "A Love Supreme", "artist": "John Coltrane", "genre": "Jazz" },
{ "title": "Mingus Ah Um", "artist": "Charles Mingus", "genre": "Jazz" },
{ "title": "Discovery", "artist": "Daft Punk", "genre": "Electronic" },
{ "title": "Mezzanine", "artist": "Massive Attack", "genre": "Electronic" },
{ "title": "The Fat of the Land", "artist": "The Prodigy", "genre": "Electronic" },
{ "title": "Play", "artist": "Moby", "genre": "Electronic" },
{ "title": "Illmatic", "artist": "Nas", "genre": "Hip hop" },
{ "title": "The Marshall Mathers LP", "artist": "Eminem", "genre": "Hip hop" },
{ "title": "To Pimp a Butterfly", "artist": "Kendrick Lamar", "genre": "Hip hop" },
{ "title": "The Chronic", "artist": "Dr. Dre", "genre": "Hip hop" },
{
"title": "The Miseducation of Lauryn Hill",
"artist": "Lauryn Hill",
"genre": "Hip hop"
},
{ "title": "Blue", "artist": "Joni Mitchell", "genre": "Folk" },
{ "title": "Harvest", "artist": "Neil Young", "genre": "Folk" },
{ "title": "Blood on the Tracks", "artist": "Bob Dylan", "genre": "Folk" },
{ "title": "Graceland", "artist": "Paul Simon", "genre": "Folk" },
{ "title": "The Freewheelin' Bob Dylan", "artist": "Bob Dylan", "genre": "Folk" },
{ "title": "Master of Puppets", "artist": "Metallica", "genre": "Metal" },
{ "title": "Paranoid", "artist": "Black Sabbath", "genre": "Metal" },
{ "title": "Reign in Blood", "artist": "Slayer", "genre": "Metal" },
{ "title": "Metallica", "artist": "Metallica", "genre": "Metal" },
{ "title": "Red Headed Stranger", "artist": "Willie Nelson", "genre": "Country" },
{ "title": "At Folsom Prison", "artist": "Johnny Cash", "genre": "Country" },
{ "title": "Golden Hour", "artist": "Kacey Musgraves", "genre": "Country" },
{ "title": "Texas Flood", "artist": "Stevie Ray Vaughan", "genre": "Blues" },
{ "title": "Live at the Regal", "artist": "B.B. King", "genre": "Blues" },
{ "title": "The Planets", "artist": "Gustav Holst", "genre": "Classical" }
]
Loading