fix(gpodder): speak the protocol AntennaPod actually sends #192
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "claude/app-opod-sync-analysis-0d1825"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Why
Goal: let PodRadar replace oPodSync. Comparing the sync endpoints with the AntennaPod source (
develop) showed that AntennaPod could not set up or sync against PodRadar at all. The existing tests passed because they encoded a contract no client uses.What changes
POST /api/2/auth/{user}/login.jsonPUTmappedPOST, creates a sessionGET /api/2/devices/{user}.json,POST /api/2/devices/{user}/{device}.jsonduring setupGET subscriptions/...?since=expecting{add, remove, timestamp}sinceignored2026-07-26T10:00:00)Notes:
since=0no removals are reported, so a freshly connected device never unsubscribes anything.PUTlogin mapping is removed; no known client uses it.Verification
Not run locally: the machine this was written on has no Maven and only JDK 21 (the project needs 25). CI on this PR is the first time the code is compiled and tested.
Tests added/updated:
Phase1IntegrationTest: new test replaying the full AntennaPod setup and sync sequence with the cookie only; existing tests moved to the real contract.GpodderServiceTest: subscription delta (adds, removes, re-added feeds,since=0).GpodderDeviceIdorTest: follows the new response shape.Main risk to watch in CI: the session behaviour of the
/api/2/**chain (Basic auth alone must not create a session; the cookie fromlogin.jsonmust authenticate later requests).Not in this PR
🤖 Generated with Claude Code
The sync endpoints were tested against a contract no client uses, so AntennaPod could not set up or sync against PodRadar: - login.json only accepted PUT; clients POST - the chain was stateless, but clients send Basic credentials on login only and rely on the session cookie afterwards - the device list/configure endpoints used during setup did not exist - GET subscriptions returned a bare list and ignored `since`; clients expect {add, remove, timestamp} - zone-less UTC timestamps (2026-07-26T10:00:00) failed to parse and were replaced by the receive time, which also defeated the dedupe Login now creates a session, device endpoints are added, subscription changes are a real delta, and the zone-less format is read as UTC. Tests follow the real contract, including one that replays the full AntennaPod setup and sync sequence using the cookie only. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>