Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[GTFS-Fares v2] Add networks.txt & route_networks.txt #405

Merged
merged 5 commits into from
Nov 28, 2023

Conversation

tzujenchanmbd
Copy link
Collaborator

Context

Currently network (grouping of routes) can be defined by routes.network_id. However, during the fares v2 working group discussions, we identified the need to separate the production of fares data. The networks.txt and route_networks.txt stem from Ito World's proposal, using a mechanism similar to areas.txt and stop.areas.txt, allowing fares data to be produced separately from schedule data.

Changes in this PR

  • Add networks.txt and route_networks.txt files
  • Modify presence of routes.network_id
  • Modify description of fare_leg_rules.network_id

This PR tries to capture consensus reached during the working group meetings:

  • Adding these two files
  • Not allowing both routes.network_id and routes_networks.txt + networks.txt in the same dataset. (presence: Conditionally Forbidden)
  • Not allowing many-to-many relationship (A route can be defined in 1 network). We can release this restriction if needed in the future.

In addition, networks.txt indicates networks are used for fares use case, we can release this restriction if needed in the future as well.

For previous discussions, please see issue#389 and working group meeting minutes.

Please go through the changes and feel free to share your thoughts/questions here.

@tzujenchanmbd tzujenchanmbd added GTFS Schedule Issues and Pull Requests that focus on GTFS Schedule Extension: GTFS-Fares Issues and Pull Requests that focus on GTFS-Fares Extension labels Oct 9, 2023
@tzujenchanmbd tzujenchanmbd linked an issue Oct 9, 2023 that may be closed by this pull request
Copy link

github-actions bot commented Nov 2, 2023

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the stale label Nov 2, 2023
@tzujenchanmbd
Copy link
Collaborator Author

not stale

@tzujenchanmbd
Copy link
Collaborator Author

Hello,

We have at least one producer: Ito World. They have shared their dataset in this file, which is part of a private feed.
We have at least one consumer: Apple Maps. Please see the screenshot below for the same dataset.

As per the GTFS amendment process, the requirements to open a vote are met.
We are opening a vote for adding networks.txt and route_networks.txt.

Please vote with a +1 (for) or -1 (against) in the comments. Voting ends on 2023-11-27 at 23:59:59 UTC.

Network_screenshot

@e-lo
Copy link

e-lo commented Nov 13, 2023

🙇‍♀️ Thank you to everyone who worked on getting this working!

+1 from me, UrbanLabs LLC

@tzujenchanmbd tzujenchanmbd added the Status: Voting Pull Requests where the advocate has called for a vote as described in the changes.md label Nov 13, 2023
@evansiroky
Copy link
Contributor

+1 from Caltrans. This does raise the question of how some best practices can be defined so that both producers can properly inform consumers of potentially separate parts of the GTFS existing in separate places.

@gcamp
Copy link
Contributor

gcamp commented Nov 14, 2023

+0 from Transit, as we said previously we don’t think independent publication is a worthy goal by itself and generally will encourage bad design practice in GTFS. We think a simple merge of data makes more sense.

That said, we recognize that we are in the overwhelming minority, so we’ll just abstain.

@westontrillium
Copy link
Contributor

+1 from Trillium


File: **Conditionally Forbidden**

Primary key (`*`)
Copy link
Collaborator

Choose a reason for hiding this comment

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

If a route_id can only be defined in one network_id, should the primary key be route_id?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yes, thanks for catching this! - 8664074


Primary key (`route_id`)

Assigns routes from [routes.txt](#stopstxt) to networks. Forbidden if `routes.network_id` field exists.
Copy link
Collaborator

Choose a reason for hiding this comment

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

Apologies, I missed this one as well. #stopstxt => #routestxt

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Thanks Brian! - f191923

@bdferris-v2
Copy link
Collaborator

+1 from Google

@tzujenchanmbd
Copy link
Collaborator Author

The vote passed on 2023-11-27 at 23:59:59 UTC.

4 votes in favour and no votes against.

The votes came from:
UrbanLabs LLC (@e-lo)
Caltrans (@evansiroky)
Trillium (@westontrillium)
Google (@bdferris-v2)

Thanks to everyone who contributed and voted!

@tzujenchanmbd tzujenchanmbd merged commit ac95ec2 into google:master Nov 28, 2023
2 checks passed
@tzujenchanmbd tzujenchanmbd removed the Status: Voting Pull Requests where the advocate has called for a vote as described in the changes.md label Nov 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Extension: GTFS-Fares Issues and Pull Requests that focus on GTFS-Fares Extension GTFS Schedule Issues and Pull Requests that focus on GTFS Schedule
Projects
None yet
Development

Successfully merging this pull request may close these issues.

GTFS-Fares v2: Add networks.txt & route_networks.txt
6 participants