~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/remote.py

  • Committer: Jelmer Vernooij
  • Date: 2011-11-27 16:05:44 UTC
  • mto: (6282.6.22 hpss-get-inventories)
  • mto: This revision was merged to the branch mainline in revision 6371.
  • Revision ID: jelmer@samba.org-20111127160544-dxeu3mxl2z8o4dxa
Only run get_checkout_format against newer servers.

Show diffs side-by-side

added added

removed removed

Lines of Context:
2947
2947
            return self._real_branch._get_checkout_format(lightweight=False)
2948
2948
 
2949
2949
    def _get_checkout_format(self, lightweight=False):
 
2950
        medium = self._client._medium
 
2951
        if medium._is_remote_before((2, 5)):
 
2952
            return self._get_checkout_format_vfs(lightweight)
2950
2953
        try:
2951
2954
            response = self._client.call('Branch.get_checkout_format',
2952
2955
                self._remote_path(), lightweight)
2953
2956
        except errors.UnknownSmartMethod:
 
2957
            medium._remember_remote_is_before((2, 5))
2954
2958
            return self._get_checkout_format_vfs(lightweight)
2955
2959
        if len(response) != 3:
2956
2960
            raise errors.UnexpectedSmartServerResponse(response)