Mercurial > hg-stable
changeset 35695:dd672e3d059f
lfs: raise an error if the server sends an unsolicited oid
This shouldn't happen. But we shouldn't ignore it if it does, because something
else is likely to go wrong.
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Wed, 17 Jan 2018 21:44:32 -0500 |
parents | 8a23082f4d93 |
children | 925107e37619 |
files | hgext/lfs/blobstore.py |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/lfs/blobstore.py Wed Jan 17 20:54:05 2018 -0500 +++ b/hgext/lfs/blobstore.py Wed Jan 17 21:44:32 2018 -0500 @@ -247,6 +247,10 @@ raise LfsRemoteError( _(('LFS server error. Remote object ' 'for "%s" not found: %r')) % (filename, response)) + else: + raise LfsRemoteError( + _('LFS server error. Unsolicited response for oid %s') + % response['oid']) if 'error' in response: raise LfsRemoteError(_('LFS server error: %r') % response)