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
Previously parse_fitness_machine_feature() returned a FitnessMachineFeature,
but now it calls parse_all_features() to return a tuple (FitnessMachineFeature, TargetSettingFeatures).
Therefore, for legacy code to work, we need to index the 0th element of the returned Tuple.
This is fine, but the function type annotation should be fixed.
Currently it's async def get_fitness_machine_feature(self) -> FitnessMachineFeature:
It should be: async def get_fitness_machine_feature(self) -> Tuple(FitnessMachineFeature, TargetSettingFeatures):
I can do that myself.
The text was updated successfully, but these errors were encountered:
Thanks to @bytosaur we have a more complete FTMS implementation, which were released in v0.4.0.
v0.4.0 included some undocumented breaking changes to the API, the first of which I'm documenting here.
FitnessMachineService
parse_fitness_machine_feature()
has a different return type and content.6ddc15c#diff-de14e22244a39d1e79b0332a8db8660f3ce2099c46e7a4df5ecf0e493a49012dR115
Previously
parse_fitness_machine_feature()
returned aFitnessMachineFeature
,but now it calls
parse_all_features()
to return a tuple(FitnessMachineFeature, TargetSettingFeatures)
.Therefore, for legacy code to work, we need to index the 0th element of the returned Tuple.
6ddc15c#diff-f85a83dec91e3b44e1518d3eb54dcd71be147857cb5cb5c07136228ed4fe704aR132
This is fine, but the function type annotation should be fixed.
Currently it's
async def get_fitness_machine_feature(self) -> FitnessMachineFeature:
It should be:
async def get_fitness_machine_feature(self) -> Tuple(FitnessMachineFeature, TargetSettingFeatures):
I can do that myself.
The text was updated successfully, but these errors were encountered: