You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
refactor: remove key transformation and align models with camelCase API responses
Remove the _transform_keys_in_data function from MlbDataAdapter that was
lowercasing all API response keys. Models now directly use the camelCase
field names returned by the MLB Stats API.
Key changes:
- Remove _transform_keys_in_data() function and its usage
- Update model field aliases to match actual API camelCase format:
* homeRun, tieBreaker, isHomeRun, isTieBreaker (homerunderby)
* dateTime, timeStamp, metaData (game models)
* inTieBreaker, tieBreakerNum (homerunderby status)
* wobaCon (stats)
- Make optional fields that may be missing in API responses:
* calendar_event_id, start_time_tbd (game models)
* wildcard_games_back, wildcard_elimination_number (standings)
- Update external tests to use camelCase field names
- Remove all mock tests and associated JSON fixtures (22,370 lines)
This simplifies the codebase by removing an unnecessary transformation
layer and ensures models directly reflect the API's native response format.
0 commit comments