File tree Expand file tree Collapse file tree 3 files changed +10
-3
lines changed Expand file tree Collapse file tree 3 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -106,7 +106,13 @@ async def process_request(
106106 json = data ,
107107 auth = auth ,
108108 ) as resp :
109- message = await resp .text ()
109+ try :
110+ message = await resp .text ()
111+ except UnicodeDecodeError :
112+ _LOGGER .debug ("Decoding error" )
113+ message = await resp .read ()
114+ message = message .decode (errors = "replace" )
115+
110116 try :
111117 message = json .loads (message )
112118 except ValueError :
Original file line number Diff line number Diff line change @@ -25,7 +25,8 @@ disable=
2525 too-many-public-methods,
2626 too-many-instance-attributes,
2727 too-many-branches,
28- too-many-statements
28+ too-many-statements,
29+ too-many-lines
2930
3031[REPORTS]
3132score =no
Original file line number Diff line number Diff line change 55
66PROJECT_DIR = Path (__file__ ).parent .resolve ()
77README_FILE = PROJECT_DIR / "README.md"
8- VERSION = "0.1.48 "
8+ VERSION = "0.1.49 "
99
1010setup (
1111 name = "python-openevse-http" ,
You can’t perform that action at this time.
0 commit comments