Closed Chreeq closed 6 years ago
In original source code, there is a try except block that make sure the data source is created. line 84-94 in https://github.com/motherapp/weight-csv-to-gfit/blob/master/import_weight_to_gfit.py
I think that your account is missing the data source record in order to put the data in.
Thanks @Chreeq finding the root cause. The change is merged.
I still get the above error, even after the merged PR. I was able to get it to work by using the dataStreamId
returned by the call fitness_service.users().dataSources().create()
.
This ID is different from the one produced by the local function get_data_source_id()
! The difference seems to be that the one returned from the create call uses number representation of the project, whereas the locally produced one uses the clear-text name of the project.
Hello,
I've been trying to make this code work again, but my very limited knowledge only got me so far. By very limited I mean that this is the first time I am interacting with python.
However I managed to fix the oAuth mechanism and some minor issues I had with the code. But I eventually end up in an error, when trying to patch my data into my gfit account.
This is where the error occurs:
My current version of the code looks like this (please excuse the excessive amount of prints and commented code. I am a horrible coder):