refactor: remove unused routes-at-stop agent #2116
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
d52ead8, which introduced more comprehensive V3 API request caching, removed the only instance where
put
was ever called on this cache, so it was effectively unused.After removing a few layers of indirection:
Stop.create_station_with_routes_map
is renamed and relocated toRoute.serving_stop
. Unclear why the previous name suggested it would "create a map".The similar-in-nature
Route.fetch_routes_by_stop
is renamed toRoute.serving_stop_with_active
so these names are aligned.Logging is added to the retry logic of
serving_stop
so we can tell whether it's still being used. This seems like a workaround for a possible bug in the V3 API which may have since been fixed, and if it hasn't been, we'll know and can report it.serving_stop_with_active
is fixed to conform to its typespec (and the spec ofLocationContext
) by returning a map containing onlyroute_id
andactive?
fields, rather than a map version of the entireRoute
struct with theid
field renamed. It appears nothing was accessing the extra fields.