Skip to content

v0.1.12: Trip blockId, schedule derivation, and routeShortName fixes

Choose a tag to compare

@cyanheads cyanheads released this 13 Jul 04:44
v0.1.12
213513d

Trip blockId, schedule derivation, and routeShortName fixes

Three data-mapping bugs found black-box testing the hosted instance: a dropped output field, an empty schedule result, and a recurring empty-string fallback bug.

Added:

  • get_trip output gains a nullable blockId, resolved from tripRef.blockId — previously unobtainable, leaving onebusaway_get_block unreachable (#15)

Fixed:

  • get_trip routeShortName no longer returns "" — new firstNonEmpty() helper skips empty strings the way ?? skips null/undefined (#15)
  • get_schedule_for_route no longer returns zero trips for an operating route — derives trips from stopTripGroupings when entry.trips is empty (#20)
  • firstNonEmpty() applied to four more call sites: normalizeRoute, getArrivals, getVehicles, getScheduleForStop (#23)

272 tests pass; bun run devcheck clean.

CHANGELOG v0.1.12