<!-- Generated by scripts/sync-agent-content.mjs. Edit the shared public sources, then regenerate. -->
# Who’s On Repeat

A multiplayer music game with shared rooms and an offline demo.

- Dates: 2026
- Status: Course project
- Areas: Software engineering
- Stack: Python · SQLite · JavaScript
- Topics: Python; JavaScript; Databases; Web/API; Games; Multiplayer; Music
- Public case study: https://mgiorgetti.com/project_details/project-whos-on-repeat.html

## Problem

A shared music game must keep rounds, private answers and scoring consistent across players' devices and reconnects.

## Contribution

Designed and implemented a multiplayer music game as a solo course project, with a Python backend, SQLite transactions and server-timed scoring.

## Technical approach and public case study

Recognize the song. Guess who listens to it. Everyone answers on their own screen while the host plays the music.

- Solo course project

- Python · FastAPI · SQLite

- JavaScript browser client

### One shared round

- Listen The host device plays the preview through a shared speaker.

- Answer Each player identifies the song and chooses the listeners.

- Reveal Answers stay private until the server advances the round.

- Score Frozen song and player facts determine the points and ranking.

### The server owns the clock

A browser cannot extend a deadline by sending an old timestamp. Commands enter a room-specific lock, use server time, and apply due transitions before handling the next action.

**Separate domains**

Rooms manages membership and listening data. Game manages rounds, answers and rankings.

**Stable scoring**

A game freezes its roster and song facts at the start. Disconnects and later lobby changes do not rewrite an earlier round.

**Recovery**

Refreshing reconnects to the room. After a server restart, interrupted games are aborted and rooms return to the lobby.

### Two ways to bring the music

#### Demo

A downloadable pack contains 100 song previews and simulated listening libraries. After setup, the demo works offline without a Spotify account.

#### Real

Spotify imports personal listening data through the same admission and game workflows. This mode needs configured provider access and approved participants. Personal Apple Music import is outside the current scope.

### Tests at the boundaries

Controlled clocks and random inputs make rule tests repeatable. SQLite and HTTP tests cover persistence, authorization and answer privacy; browser-controller tests cover screen and audio behavior. Live provider access and multi-device audio have separate manual checks.

## Results and limitations

The offline demo uses a downloadable pack of 100 previews and simulated listening libraries. Spotify mode requires configured provider access and approved participants. Personal Apple Music import is outside scope; live-provider and multi-device audio checks remain separate from automated rule tests.

## Public supporting links

- [Portfolio case study](https://mgiorgetti.com/project_details/project-whos-on-repeat.html)
- [Explore the source](https://github.com/Inventure72/DevOpsAssignement)
- [Run the demo](https://github.com/Inventure72/DevOpsAssignement#run)
- [Matteo Giorgetti profile](https://mgiorgetti.com/profile.md)
