mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-03-25 08:55:50 +00:00
Log error response body in debug
This commit is contained in:
parent
388c16f188
commit
84ff0ac943
1 changed files with 4 additions and 0 deletions
|
|
@ -223,6 +223,10 @@ async def request(
|
|||
logger.debug(response.headers)
|
||||
logger.debug(response.content)
|
||||
|
||||
if logger.getEffectiveLevel() <= logging.DEBUG and response.status >= 400:
|
||||
# https://github.com/pimutils/vdirsyncer/issues/1186
|
||||
logger.debug(await response.text())
|
||||
|
||||
if response.status == 412:
|
||||
raise exceptions.PreconditionFailed(response.reason)
|
||||
if response.status in (404, 410):
|
||||
|
|
|
|||
Loading…
Reference in a new issue