Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5870a99

Browse files
committed
Don't throw exceptions on unprocessed hrefs in get_multi
Rather, just log them. This allows my calendar sync to continue to workeven if some of the hrefs can't be retrieved. In my case, one of thehrefs on my calendar was always returning a 404, so I want to skip it.
1 parentc54d7fd commit5870a99

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

‎vdirsyncer/storage/dav.py‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -547,7 +547,7 @@ async def get_multi(self, hrefs):
547547
else:
548548
rv.append((href,Item(raw),etag))
549549
forhrefinhrefs_left:
550-
raiseexceptions.NotFoundError(href)
550+
dav_logger.warning(f"Skipping{href}, not found")
551551

552552
forhref,item,etaginrv:
553553
yieldhref,item,etag
@@ -645,6 +645,7 @@ def _parse_prop_responses(self, root, handled_hrefs=None):
645645
props=response.findall("{DAV:}propstat/{DAV:}prop")
646646
ifpropsisNoneornotlen(props):
647647
dav_logger.debug(f"Skipping{href!r}, properties are missing.")
648+
dav_logger.debug(f"Response for{href!r}:{etree.tostring(response)}")
648649
continue
649650
else:
650651
props=_merge_xml(props)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp