toogoodtogo-ha-mqtt-bridge
toogoodtogo-ha-mqtt-bridge copied to clipboard
Get banned every week
I live in France and every week i am banned. If i reboot my modem, with a new IP it works again.
My config is :
language: en-US polling_schedule: "*/20 * * * *" intense_fetch_interval: 30 intense_fetch_period_of_time: 5
In the log i have this error :
Traceback (most recent call last): File "/usr/local/lib/python3.8/threading.py", line 932, in _bootstrap_inner self.run() File "/usr/local/lib/python3.8/threading.py", line 870, in run self._target(*self._args, **self._kwargs) File "/app/toogoodtogo_ha_mqtt_bridge/main.py", line 303, in fetch_loop if not check(): File "/app/toogoodtogo_ha_mqtt_bridge/main.py", line 46, in check shops = tgtg_client.get_items(page_size=400) File "/usr/local/lib/python3.8/site-packages/tgtg/init.py", line 256, in get_items raise TgtgAPIError(response.status_code, response.content) tgtg.exceptions.TgtgAPIError: (403, b'
Please enable JS and disable any ad blocker
Let the api cool down over night. My cron looks like this and I never get banned:
"polling_schedule": "*/2 8-19 * * *", "intense_fetch": {"interval": 30, "period_of_time": 1}
Thank you i will try this
Get banned again :
polling_schedule: "*/10 7-20 * * *" intense_fetch_interval: 30 intense_fetch_period_of_time: 1
Are you running multiple tgtg bridges ?
No, i run only one on my home assistant on a raspberry pi and my IOS app is still working with Home Wifi
All my settings :
Maybe language parameter is important to not be banned. In language i wrote "fr-FR" i will try with "fr".
Yes, please try this
Any update on this? I got the same error.
Can someone better explain how the intense fetch works?
Any update on this? I got the same error.
It's still some kind of ~magic~ blackbox how these rate limiter works. As far as I can tell, I get banned too, when running multiple instances at the same time.
Can someone better explain how the intense fetch works?
What is your question in detail?
There are some words written here: https://github.com/MaxWinterstein/toogoodtogo-ha-mqtt-bridge#tgtgintense_fetch-optional