Skip to content

Remove export original route & service exception types feature flags#14

Merged
mmathieum merged 1 commit into
masterfrom
mm/remove_ff_gtfs_export_orig_route_service_except_types
Nov 4, 2025
Merged

Remove export original route & service exception types feature flags#14
mmathieum merged 1 commit into
masterfrom
mm/remove_ff_gtfs_export_orig_route_service_except_types

Conversation

@mmathieum

@mmathieum mmathieum commented Nov 4, 2025

Copy link
Copy Markdown
Member

@mmathieum mmathieum marked this pull request as draft November 4, 2025 16:17
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello @mmathieum, 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 streamlines the data export process by removing two feature flags: F_EXPORT_ORIGINAL_ROUTE_TYPE and F_EXPORT_SERVICE_EXCEPTION_TYPE. This change signifies that the functionalities previously guarded by these flags are now standard behavior, leading to a cleaner codebase and more consistent data output for route and service exception types.

Highlights

  • Feature Flag Removal: The feature flags F_EXPORT_ORIGINAL_ROUTE_TYPE and F_EXPORT_SERVICE_EXCEPTION_TYPE have been removed, indicating that the functionality they controlled is now considered stable and always enabled.
  • Code Simplification: The removal of these feature flags has led to significant code simplification by eliminating conditional logic and nullable types that were previously required to support the flags.
  • Data Export Consistency: Original route types and service exception types are now consistently exported without conditional checks, streamlining data processing and ensuring a unified data format.
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 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 counter productive. 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.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

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.

@mmathieum mmathieum self-assigned this Nov 4, 2025
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello @mmathieum, 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 streamlines the data parsing and export process by eliminating two feature flags that previously controlled the inclusion of original route types and service exception types. By removing these flags, the system now consistently exports these data points, simplifying the codebase and ensuring a more uniform data structure. This change indicates that the functionality previously guarded by these flags is now considered stable and essential for all data exports.

Highlights

  • Feature Flag Removal: The pull request removes the F_EXPORT_ORIGINAL_ROUTE_TYPE and F_EXPORT_SERVICE_EXCEPTION_TYPE feature flags, simplifying the data export logic.
  • Consistent Data Export: Original route types and service exception types are now consistently exported without being gated by feature flags, ensuring these attributes are always included in the output.
  • Code Simplification: Conditional logic based on these feature flags has been removed, leading to cleaner and more straightforward code in GenerateMObjectsTask.java, MRoute.kt, and MServiceDate.kt.
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 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 counter productive. 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.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

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.

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

Copy link
Copy Markdown
Contributor

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 successfully removes the F_EXPORT_ORIGINAL_ROUTE_TYPE and F_EXPORT_SERVICE_EXCEPTION_TYPE feature flags, making the corresponding features permanently enabled. The changes are applied consistently across GenerateMObjectsTask.java, MDataChangedManager.kt, MRoute.kt, and MServiceDate.kt. The removal of conditional logic simplifies the code and improves maintainability. Notably, MRoute.type has been improved to be non-nullable, and MServiceDate.toCalendarDate now has a cleaner implementation. The related adjustment in MDataChangedManager.kt is also correct. Overall, this is a solid refactoring with no apparent issues.

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

Copy link
Copy Markdown
Contributor

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 effectively removes the F_EXPORT_ORIGINAL_ROUTE_TYPE and F_EXPORT_SERVICE_EXCEPTION_TYPE feature flags, enabling these features by default. The changes are clean, consistent, and improve code readability by removing conditional logic. A notable improvement is the change in MServiceDate.toCalendarDate, which now returns a non-nullable type, fixing a potential latent bug in MDataChangedManager.kt. I have one suggestion to further improve the code by reducing duplication.

Comment thread src/main/java/org/mtransit/parser/mt/data/MServiceDate.kt
@mmathieum mmathieum marked this pull request as ready for review November 4, 2025 16:25
@mmathieum mmathieum merged commit 475e62c into master Nov 4, 2025
1 check passed
@mmathieum mmathieum deleted the mm/remove_ff_gtfs_export_orig_route_service_except_types branch November 4, 2025 16:32
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