Fancy branches versus Transports
John A Meinel
john at arbash-meinel.com
Sat Sep 17 06:12:01 BST 2005
Lalo Martins wrote:
> And so says John A Meinel on 16/09/05 22:35...
> FWIW, one of the motivations for the new constructors was to make it
> easier for you to do exactly what you want to do.
> The LocalBranch class was created as the first step of an attempt to
> drill down which Branch methods deal with the filesystem (those would
> remain in LocalBranch) and which are just branch logic (those would
> float up back to Branch). In the end, it would be possible for
> RemoteBranch to subclass Branch.
> Then you came back from vacation and made this effort irrelevant ;-)
> So if you're already getting rid of RemoteBranch, feel free to get rid
> of LocalBranch too (folding it back into Branch). The drilling down
> part was already done in your previous branch.
> Another reason the LocalBranch wasn't removed before my branch was
> merged, is that we wanted to make the Branch constructor abstract, so
> that we could quickly catch all code that uses it and move it to the new
I'm happy to see this part.
> So, if you have one single class, I suppose you have to have an usable
> constructor (unless you want to define __new__ and make it raise
> something). I'm not sure what should be the result of Branch(foo) -
> maybe equivalent to Branch.open(foo)? But that doesn't smell very good.
> Anyway, the current implementation of the constructors (by
> implementation I mean the code inside the methods themselves) is clearly
> temporary; it was intended to introduce the new API asap, giving us an
> opportunity to migrate calling code. (Right now it just wraps the old
> constructor.) A more complete implementation would have been a waste of
> time, since I was expecting either you or me to further change branch
> construction in the direction of transports and storages.
> In short - keep the API (namely, you build a branch by calling one of
> the three constructors, and no other way), and blow away the internals
> as much as you want. If there is anything I can do to help, just ask.
Well, my branch is back up and running at:
It has merged all of the mainline code, and most of the integration stuff.
I believe I have it passing all of the tests, though I have had
intermittent problems with the HttpServer complaining about "resource
temporarily unavailable". That seems to be a problem with the python
HttpServer, and not bzr.
Anyway, I haven't thoroughly gone through all of the code, nor written
all of the test cases that I want to have done. But in general, I think
the code is at the point where people might start poking at it, and
seeing if it pops.
> Lalo Martins
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 253 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20050917/f8bd56bb/attachment.pgp
More information about the bazaar