Skip to content

feat: use effective release date for episodes#147

Open
michaldrabik wants to merge 3 commits into
mainfrom
feature/effective-date
Open

feat: use effective release date for episodes#147
michaldrabik wants to merge 3 commits into
mainfrom
feature/effective-date

Conversation

@michaldrabik
Copy link
Copy Markdown
Collaborator

No description provided.

@michaldrabik michaldrabik self-assigned this May 13, 2026
@gemini-code-assist
Copy link
Copy Markdown

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request introduces an effectiveReleaseDate to the Episode model, providing a more accurate way to determine when an episode is released. It consolidates release date logic into a new releasedAt property and migrates the model to use Instant instead of ZonedDateTime. Additionally, various UI components were updated to leverage these changes, simplifying release status checks and improving date handling across the application.

Highlights

  • Model Refactoring: Added effectiveReleaseDate to the Episode model and introduced a unified releasedAt property to handle release date logic consistently.
  • Data Type Migration: Migrated the Episode model from ZonedDateTime to Instant for improved timestamp handling and consistency across the application.
  • UI Component Updates: Updated numerous UI components to leverage the new releasedAt property and simplified release status checks using the new rememberReleased helper.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request migrates the Episode model from ZonedDateTime to Instant and introduces an effectiveReleaseDate field, consolidating release logic into a new releasedAt property and a rememberReleased() Composable helper. The feedback highlights logic inversions in EpisodeSeasonEpisodesList.kt and ShowEpisodesList.kt where 'upcoming' chips are incorrectly shown for released episodes. Additionally, suggestions were made to improve the precision of Instant comparisons in the isReleased check and to simplify the EpisodeHeader logic using the new helper.

Comment thread common/src/main/java/tv/trakt/trakt/common/model/Episode.kt Outdated
@michaldrabik
Copy link
Copy Markdown
Collaborator Author

/gemini review

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the Episode model to use Instant instead of ZonedDateTime and introduces an effectiveReleaseDate field to improve release date handling. It updates various UI components to use releasedAt and the new rememberReleased() helper for consistent release status checks. The review identified two logic inversions in UI components where the upcoming episode chip was incorrectly displayed for released episodes, as well as a suggestion to simplify the isReleased property implementation in the Episode model.

Comment thread common/src/main/java/tv/trakt/trakt/common/model/Episode.kt Outdated
@michaldrabik
Copy link
Copy Markdown
Collaborator Author

/gemini review

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the Episode model to introduce effectiveReleaseDate and a unified releasedAt property, replacing the previous firstAired logic. It updates various UI components to use this new releasedAt property and the rememberReleased() helper method for consistency. The reviewer provided a suggestion to simplify the isReleased property implementation in Episode.kt for better readability and safety.

Comment thread common/src/main/java/tv/trakt/trakt/common/model/Episode.kt Outdated
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the Episode model to use Instant instead of ZonedDateTime and introduces effectiveReleaseDate and releasedAt properties. It also adds a rememberReleased() Composable helper and updates numerous UI components across the mobile and TV modules to use these new fields for release status and date formatting. A review comment suggests simplifying the isReleased getter in Episode.kt to be more idiomatic.

Comment thread common/src/main/java/tv/trakt/trakt/common/model/Episode.kt Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant