Private
Public Access
1
0

small improvement activity chart; retiring Bike, only bike with small b

This commit is contained in:
Sander Roosendaal
2021-05-10 18:44:01 +02:00
parent 5fc274e834
commit 5fc34419b8
5 changed files with 21 additions and 27 deletions

View File

@@ -35,11 +35,11 @@ from pytz import timezone as tz, utc
#http_client.HTTPConnection.debuglevel = 1
# You must initialize logging, otherwise you'll not see debug output.
logging.basicConfig()
logging.getLogger().setLevel(logging.DEBUG)
requests_log = logging.getLogger("requests.packages.urllib3")
requests_log.setLevel(logging.DEBUG)
requests_log.propagate = True
#logging.basicConfig()
#logging.getLogger().setLevel(logging.DEBUG)
#requests_log = logging.getLogger("requests.packages.urllib3")
#requests_log.setLevel(logging.DEBUG)
#requests_log.propagate = True
from rowers.tasks import handle_get_garmin_file
@@ -305,12 +305,6 @@ def ps_to_garmin(ps,r):
payload['steps'] = lijst
url = 'https://apis.garmin.com/training-api/workout/'
print(payload)
print(oauth_data['client_id'])
print(oauth_data['client_secret'])
print(r.garmintoken)
print(r.garminrefreshtoken)
garmin = OAuth1Session(oauth_data['client_id'],
client_secret=oauth_data['client_secret'],
resource_owner_key=r.garmintoken,
@@ -319,7 +313,6 @@ def ps_to_garmin(ps,r):
encoding='base64'
)
print(garmin.headers)
response = garmin.post(url,data=payload)