We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e7ccf54 commit 8b4b3d6Copy full SHA for 8b4b3d6
custom_components/tarif_edf/coordinator.py
@@ -33,8 +33,13 @@
33
_LOGGER = logging.getLogger(__name__)
34
35
def get_remote_file(url: str):
36
- response = requests.get(url, stream = True)
37
- return response
+ return requests.get(
+ url,
38
+ stream=True,
39
+ headers={
40
+ "User-Agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.103 Safari/537.36"
41
+ },
42
+ )
43
44
def str_to_time(str):
45
return datetime.strptime(str, '%H:%M').time()
0 commit comments