Repository navigation
Serve alerts.pb, weather.json and vehicles.json (production cutover blocker) - #80
Conversation
The shipped iOS and Android apps request GET /api/v1/regions/{id}/alerts.pb
and /weather.json, and the legacy Rails app also served /vehicles.json
(its migrated-region redirect preserves the full path). The sidecar only
registered the bare paths, so those requests hit Go's default 404 and
region-wide alerts and weather broke for any region moved to the sidecar.
Register the suffixed paths on the same handlers, keeping weather's
deliberate 403-when-unavailable. alerts.json is intentionally not served:
Rails only answered pb and pbtext. Update the OpenAPI spec, README, spec
doc, and make deploy/smoke.sh probe alerts.pb.
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
|
Code reviewNo issues found. Checked for bugs and CLAUDE.md compliance. 🤖 Generated with Claude Code |
|
Maintainer sweep: this one is ready to land on the merits, but I'm not merging it in this pass because it's authored by the account running the sweep, and I don't approve or merge my own PRs. It needs an approval and merge from another maintainer. What I checked myself, beyond the automated review:
Heads-up: #81 and #83 also touch |
|
PR sweep disposition: blocked — not merged. I authored this PR, so the sweep can't approve or merge it. I re-read the full diff at To unblock: another maintainer approves and merges it. |



Problem
The shipping iOS and Android apps request
GET /api/v1/regions/{id}/alerts.pb(optionally?test=1) andGET /api/v1/regions/{id}/weather.json(iOS:ObacoAPIService.swift,RESTAPIURLBuilder.swift; Android:donottranslate.xml). The sidecar only registered/alerts,/alerts.pbtext,/weather,/vehicles, so both requests got Go's default 404. Region-wide alerts and weather would break for every region moved to the sidecar. The Rails migrated-region redirect preservesrequest.fullpath, so suffixed paths arrive here unchanged.Changes
alerts.pb-> same handler as/alerts(binary feed, content type, cache headers,?test=1).weather.json-> same handler as/weather(including the deliberate 403 when unavailable).vehicles.json-> same handler as/vehicles(Rails routed it with format json; redirect preserves it).alerts.json(Rails only answered pb/pbtext; no JSON representation exists here, stays 404, now tested). Alarms/push/live-activity/ghost-bus/survey-response paths: no client emits a suffix, so unchanged.specification/openapi.yaml,specification/specification.md, README updated;deploy/smoke.shnow probesalerts.pb.Testing
Tests written first and confirmed failing with 404, then routes added: alerts.pb vs /alerts (body + Content-Type + Cache-Control, with and without
?test=1, unknown region 404), alerts.json 404, weather.json vs /weather for 200/403/404, vehicles.json vs /vehicles.make check(fmt-check, vet, golangci-lint, generate-check, test, test-tz, test-race, web-check) passes.Summary by CodeRabbit
New Features
.pbalerts and.jsonweather and vehicle-search endpoint variants. Each returns the same results as its corresponding existing endpoint.Bug Fixes
.pbalerts path.