hgext/largefiles/remotestore.py
changeset 44452 9d2b2df2c2ba
parent 43105 649d3ac37a12
child 45942 89a2afe31e82
equal deleted inserted replaced
44449:ff72bd52d56a 44452:9d2b2df2c2ba
    46             _(b'remotestore: put %s to remote store %s\n')
    46             _(b'remotestore: put %s to remote store %s\n')
    47             % (source, util.hidepassword(self.url))
    47             % (source, util.hidepassword(self.url))
    48         )
    48         )
    49 
    49 
    50     def exists(self, hashes):
    50     def exists(self, hashes):
    51         return dict(
    51         return {
    52             (h, s == 0)
    52             h: s == 0
    53             for (h, s) in pycompat.iteritems(
    53             for (h, s) in pycompat.iteritems(
    54                 self._stat(hashes)
    54                 self._stat(hashes)
    55             )  # dict-from-generator
    55             )  # dict-from-generator
    56         )
    56         }
    57 
    57 
    58     def sendfile(self, filename, hash):
    58     def sendfile(self, filename, hash):
    59         self.ui.debug(b'remotestore: sendfile(%s, %s)\n' % (filename, hash))
    59         self.ui.debug(b'remotestore: sendfile(%s, %s)\n' % (filename, hash))
    60         try:
    60         try:
    61             with lfutil.httpsendfile(self.ui, filename) as fd:
    61             with lfutil.httpsendfile(self.ui, filename) as fd: