Skip to content

Add poster_path, backdrop_path and release_date to Movie/TV models - #487

Merged
felixschndr merged 3 commits into
joostlek:mainfrom
willmakenoise:feat/poster-backdrop-fields
Oct 28, 2026
Merged

felixschndr merged 3 commits into
joostlek:mainfrom
willmakenoise:feat/poster-backdrop-fields

Conversation

@willmakenoise

@willmakenoise willmakenoise commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Problem

Search results (Movie, TV) and detail lookups (MovieDetails, TVDetails) don't expose poster/backdrop images, even though the API returns them. Movie also doesn't expose a release date, even though MovieDetails already does.

Confirmed against the existing test fixtures (tests/fixtures/*/search_1.json, search_2.json, movie.json, tv.json) — posterPath, backdropPath, and (for search results) releaseDate are all present in real API responses, just not modeled.

Change

  • Movie, TV: add poster_path/backdrop_path (optional — posterPath is frequently null in practice).
  • Movie: add release_date (date | None). The API can send "" rather than omitting the field when unknown, so this uses the same deserialize_optional_date approach Handle empty TV first air dates #496 added for TV.first_air_date, treating an empty string as None instead of failing date.fromisoformat.
  • MovieDetails, TVDetails: add poster_path/backdrop_path for the same reason.

Testing

  • Snapshot file updated (--snapshot-update); diff is purely additive/type-representation only — no existing fields changed or removed, aside from Movie.release_date now showing as datetime.date(...) / None instead of a raw string.
  • The empty-release_date case is already exercised by the existing search_1.json/search_2.json fixtures (e.g. "Frosty"), so no new fixture was needed — reverting the deserializer causes those existing tests to fail with ValueError: Invalid isoformat string: '', not just a snapshot mismatch.
  • Full suite, ruff, pylint, and mypy all pass locally.

@felixschndr felixschndr added the new-feature New features or options. label Oct 28, 2026
@felixschndr felixschndr self-assigned this Oct 28, 2026
@felixschndr
felixschndr merged commit 3647bcb into joostlek:main Oct 28, 2026
12 checks passed
@github-actions github-actions Bot locked and limited conversation to collaborators Oct 30, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

new-feature New features or options.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants