Skip to content

feat: modify /plan-journey so it returns bus polylines, /getAllRoutes & /getAllRideRoutes to return processed data - #47

Draft
jumpy-cat wants to merge 53 commits into
devfrom
nav/plan-journey-bus-polylines
Draft

feat: modify /plan-journey so it returns bus polylines, /getAllRoutes & /getAllRideRoutes to return processed data#47
jumpy-cat wants to merge 53 commits into
devfrom
nav/plan-journey-bus-polylines

Conversation

@jumpy-cat

@jumpy-cat jumpy-cat commented Jul 25, 2026

Copy link
Copy Markdown
Member

Description

Move the majority of bus route line processing into the backend so that more information in available during journey planning. (WIP) Modify plan journey so that its bus legs contain polyline info. (WIP) refactor all changed routes to use documented.

Type of Change

  • New feature (feat)
  • Bug fix (fix)
  • Refactor / code improvement
  • Dependency / build update
  • Documentation
  • Other (explain)

Related Issues

Backend Side of mbusdev/bluebus-flutter#98

Changes Made

  • Flutter: n/a
  • Backend (TypeScript):
    • the responses from bustime servers /getpatterns are now checked against zod schemas before being processed into BusRouteLines similar to those used in the frontend (but missing a few fields)
    • existing usages of routes / ride routes refactored to use processed bus route lines
  • Firebase / Shared: n/a

Testing Done

Flutter:

  • Tested on:
    • iOS Simulator
    • Android Emulator
    • Physical device

Screenshots / Demo (if UI or notification change)

Checklist

  • Commit messages follow Conventional Commits
  • PR title follows [type](scope): short description
  • PR target branch is not main and is our current working update branch (e.g. maizebus2.1)
  • No print() / debugPrint() / console.log() left in production code
  • Secrets / keys not committed

Edward Zhang and others added 30 commits June 20, 2026 12:45
Replace the any returned by processJourneys with an actual type that models the two variant nature of the processed legs. Did a similar thing with the journey leg type in `McRaptorAlgorithm.ts`. Both changes should have no semantic difference but behavior and performance should ideally both be checked.
These wrappers add zod-based input validation, type-safety, and reflection capabilities. To be used in the future for generating openapi definitions.
Also reordered the definitions so that the main api is together and
closer to the top + fixed a bug where req & res bodies were mixed up.
Logic was ported from the frontend, which shall be changed to rely on
the result from the backend.
@jumpy-cat jumpy-cat changed the title feat: modify /plan-journey so it returns bus polylines, uses documented feat: modify /plan-journey so it returns bus polylines, /getAllRoutes & /getAllRideRoutes to return processed data Jul 25, 2026
@jumpy-cat
jumpy-cat force-pushed the nav/plan-journey-bus-polylines branch from 56bf050 to 032b194 Compare July 25, 2026 14:20
@jumpy-cat
jumpy-cat force-pushed the nav/plan-journey-bus-polylines branch from 032b194 to e5f4055 Compare July 25, 2026 21:44
@jumpy-cat jumpy-cat changed the title feat: modify /plan-journey so it returns bus polylines, /getAllRoutes & /getAllRideRoutes to return processed data feat: modify /getAllRoutes & /getAllRideRoutes to return processed data Jul 26, 2026
@jumpy-cat jumpy-cat changed the title feat: modify /getAllRoutes & /getAllRideRoutes to return processed data feat: modify /plan-journey so it returns bus polylines, /getAllRoutes & /getAllRideRoutes to return processed data Jul 26, 2026
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