From f62263e287339f05cba20018204e0c85e540046a Mon Sep 17 00:00:00 2001 From: avollkopf <43980694+avollkopf@users.noreply.github.com> Date: Sun, 4 Jul 2021 13:39:25 +0200 Subject: [PATCH] Update upload_controller.py Increase limit of BF recipes to 50 next Steps: add offset parameter to start also with recipe 51,.... --- cbpi/controller/upload_controller.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cbpi/controller/upload_controller.py b/cbpi/controller/upload_controller.py index 702afa7..dacc243 100644 --- a/cbpi/controller/upload_controller.py +++ b/cbpi/controller/upload_controller.py @@ -73,9 +73,9 @@ class UploadController: if brewfather == True: encodedData = base64.b64encode(bytes(f"{brewfather_user_id}:{brewfather_api_key}", "ISO-8859-1")).decode("ascii") headers={"Authorization": "Basic %s" % encodedData} - + parameters={"limit": 50} async with aiohttp.ClientSession(headers=headers) as bf_session: - async with bf_session.get(self.url) as r: + async with bf_session.get(self.url, params=parameters) as r: bf_recipe_list = await r.json() await bf_session.close()