[MERGE] Make 'bzr upgrade' work over HPSS.
Andrew Bennetts
andrew at canonical.com
Wed Jul 30 01:18:16 BST 2008
John Arbash Meinel wrote:
[...]
>
> Poking at 'self.bzrdir._real_bzrdir' seems a bit iffy. Maybe adding a
> 'get_real_bzrdir()' to RemoteBzrDir and then having a:
>
> get_real = getattr(self.bzrdir, 'get_real_bzrdir', None)
> if get_real is not None:
> ~ self.bzrdir = get_real()
Well, that self.bzrdir._real_bzrdir is already guarded by an isinstance check
for RemoteBzrDir. So I don't think the extra complexity really buys us anything
here. A new API is another name for the reader to remember and understand, if
we don't underscore it then we're inviting code outside of bzrlib to use it
which means being careful about compatibility, etc. The existing approach seems
simple and adequate to me.
> I really like that you can upgrade over HPSS, I'm not a big fan of
> poking at private members if we can help it.
Well, it's private to bzrlib. bzrlib.repository already does similar things in
an InterRepository.
-Andrew.
More information about the bazaar
mailing list