Closed ml31415 closed 1 year ago
Agreed on your thoughts above. I prefer mapping the API as closely as possibly, it tends to lead to less confusion overall, so slight preference for leaving as it but definitely not opposed.
I think users will invariably write nicer wrappers over Betfair parsers for their own patterns or uses, so fine for us to stay closely matching the API and docs.
Alright. I guess I might just add some @property
s for aliasing then.
The streaming messages contain a lot of cryptic fields like "pt", "ct", "batb" and so on. While this makes sense in order to save bandwith, it doesn't make sense for us to have the object attributes named like that, as
msgspec
is perfectly capable of translating the names under the hood as we already do with the camel case to snake case translation.On one hand, it would make working with the API a bit nicer and self explanatory, on the other hand, it would make the string representations of the messages more lengthy and verbose. Also, it's a breaking change.
@limx0 What do you think, is it worth to rename the fields?