Add vehicle_crew supporting table - #246
Conversation
|
Documentation available at: |
|
Data Validation Report
|
|
Data Validation Report
|
This warning is because the frictionless validation check can't find the |
There was a problem hiding this comment.
I believe this meets the needs discussed in the issue. However, it looks like this PR accidentally removes trip_id_performed from the trips_performed table. I also suspect that trip_id_performed should be required if it's part of the primary key. Though to be fair, it doesn't strictly need to be, service_date, crew_id and start_time should be sufficient for the primary key. Including trip_id_performed just makes it easier to use.
- undo removal of
trips_performed.trip_id_performed
…hicle_crew, clean up CHANGELOG whitespace
|
Data Validation Report
|
|
Accepted with minor changes I think this is a useful addition and addresses the core limitation identified in #220: I have a few points that I think are worth clarifying before finalizing the schema:
(Kindly consider these mostly as semantic/integrity clarifications rather than objections to the overall approach.) |
|
Thank you @jabhij for the great comments/questions. Here are my thoughts:
We should probably update the name of the
My understanding is that a trip that is performed by multiple vehicles (e.g., vehicle switch or doubled up) should be represented by multiple
I don't have an opinion on whether Does overlapping crew assignments mean that same |
|
Thank you @jlstpaul for the thoughtful response. I agree with the direction, especially treating A few follow-up thoughts:
Overall, I think these clarifications would make the intended relationships and temporal semantics much clearer without changing the core approach. |
|
I noticed the use of the word crew while TODS uses employee. Does this make any difference to the spec? |
|
@mpaine-act We considered "employee" and other words, but settled for "crew" because (1) it is shorter, (2) it is more specific to employees that perform functions in vehicles and stations (not administration), and (3) it could include contractors that are technically not employees. |
@jabhij It was not my intent to differentiate |
Summary
Adds new
vehicle_crewtable to support multiple crew members per vehicle/trip, including mid-trip reliefs. This addresses the limitation wheretrips_performed.operator_idcould only reference a single operator.Resolves #220
Changes
spec/vehicle_crew.schema.json(new) defines thevehicle_crewtable with:[service_date, trip_id_performed, crew_id, start_time]service_date,vehicle_id,crew_id,start_timetrip_id_performed(for vehicle-level assignments),crew_role,end_timecrew_roleenum:operator,conductor,fare_inspector,other(uses snake_case consistent with 🐛📄 – Improve event_type naming convention in passenger_events #235)trips_performed,vehicles, andoperatorssamples/template/TIDES/vehicle_crew.csv(new) provides header-only templatespec/trips_performed.schema.jsonupdatedoperator_iddescription to clarify optional usage and reference tovehicle_crewtable for multi-operator scenariosspec/tides-datapackage-profile.jsonaddedvehicle_crewtotides-tableenumsamples/template/TIDES/datapackage.jsonaddedvehicle_crewresource entryCHANGELOG.mdadded entries under[Unreleased]for new table and description changeReason for this change
Rail systems commonly have multiple crew members (operators, conductors) on a single trip, and operator reliefs mid-trip are standard practice. The current
trips_performed.operator_idfield can only reference one operator, forcing agencies to either lose crew data or pick an arbitrary operator to record.The new
vehicle_crewtable allows agencies to capture complete crew assignment history while keeping the existingoperator_idfield for simple single-operator cases.- See related discussion in Issue #220 and Fall 2025 TIDES Issues Working Group notes from December 1 and December 10.
Review checklist
Per change management policy, the following must be met before feature branch changes can merge to
developbranch:Community review status (updated August 27, 2026)
How community review works: Per the TIDES Change Management Policy, a proposal moves forward once at least three TIDES Contributors outside the originating working group publicly comment with a score: Accepted, Accepted with minor changes, or Substantially revised. A few sentences with your read of the proposal is a complete review.
Originating working group (Fall 2025 Issues Working Group, December 1 and 10, 2025 sessions): Christopher Yamas, Gabriel Sánchez Martínez, Ian Thistle, Jay Gordon, John Levin, Joey Reid, Spenser Sutinen. Their work is reflected in the proposal itself; community review comes from Contributors beyond this group.
Review so far: Laurie Merrell (@laurie-jarvus) and @jabhij have posted scored reviews (Accepted; Accepted with minor changes, with clarifications answered in the thread). One more review from a Contributor outside the working group completes community review.
Community review remains open, and reviews are welcome while we finalize v2.0. If you have not yet weighed in, a short comment closing with where you land (Accepted / Accepted with minor changes / Substantially revised) is all we need.