mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-04-27 14:57:41 +00:00
DAV: Remove warning about missing etag on PUT
This commit is contained in:
parent
7f705aeb3a
commit
4b0a896303
1 changed files with 6 additions and 4 deletions
|
|
@ -445,11 +445,13 @@ class DavStorage(Storage):
|
||||||
etag = response.headers.get('etag', None)
|
etag = response.headers.get('etag', None)
|
||||||
href = self._normalize_href(response.url)
|
href = self._normalize_href(response.url)
|
||||||
if not etag:
|
if not etag:
|
||||||
dav_logger.warning('Race condition detected with server {}, '
|
# The server violated the RFC and didn't send an etag.
|
||||||
'consider using an alternative.'
|
# ownCloud: https://github.com/owncloud/contacts/issues/920
|
||||||
.format(self.session.parsed_url.netloc))
|
dav_logger.debug('Server did not send etag, fetching {!r}'
|
||||||
|
.format(href))
|
||||||
item2, etag = self.get(href)
|
item2, etag = self.get(href)
|
||||||
assert item2.uid == item.uid
|
if item2.raw != item.raw:
|
||||||
|
raise exceptions.WrongEtagError(href)
|
||||||
return href, etag
|
return href, etag
|
||||||
|
|
||||||
def update(self, href, item, etag):
|
def update(self, href, item, etag):
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue