##// END OF EJS Templates
largefiles: don't mute and obfuscate http errors when putlfile fails...
Mads Kiilerich -
r26825:78539633 stable
parent child Browse files
Show More
@@ -86,15 +86,14 b' def wirereposetup(ui, repo):'
86 86 # input file-like into a bundle before sending it, so we can't use
87 87 # it ...
88 88 if issubclass(self.__class__, httppeer.httppeer):
89 res = None
89 res = self._call('putlfile', data=fd, sha=sha,
90 headers={'content-type':'application/mercurial-0.1'})
90 91 try:
91 res = self._call('putlfile', data=fd, sha=sha,
92 headers={'content-type':'application/mercurial-0.1'})
93 92 d, output = res.split('\n', 1)
94 93 for l in output.splitlines(True):
95 94 self.ui.warn(_('remote: '), l) # assume l ends with \n
96 95 return int(d)
97 except (ValueError, urllib2.HTTPError):
96 except ValueError:
98 97 self.ui.warn(_('unexpected putlfile response: %r\n') % res)
99 98 return 1
100 99 # ... but we can't use sshrepository._call because the data=
@@ -209,12 +209,10 b' Test coverage of error handling from put'
209 209 $ hg serve -R ../mirror -d -p $HGPORT1 --pid-file hg.pid --config largefiles.usercache=$TESTTMP/mirrorcache
210 210 $ cat hg.pid >> $DAEMON_PIDS
211 211
212 (the following push fails but doesn't show why)
213 212 $ hg push http://localhost:$HGPORT1 -f --config files.usercache=nocache
214 213 pushing to http://localhost:$HGPORT1/
215 214 searching for changes
216 unexpected putlfile response: None
217 abort: remotestore: could not put $TESTTMP/src/.hg/largefiles/e2fb5f2139d086ded2cb600d5a91a196e76bf020 to remote store http://localhost:$HGPORT1/
215 abort: remotestore: could not open file $TESTTMP/src/.hg/largefiles/e2fb5f2139d086ded2cb600d5a91a196e76bf020: HTTP Error 403: ssl required
218 216 [255]
219 217
220 218 $ rm .hg/largefiles/e2fb5f2139d086ded2cb600d5a91a196e76bf020
General Comments 0
You need to be logged in to leave comments. Login now