l.c.v.b.BranchTransportDispatch : class documentation

Part of lp.codehosting.vfs.branchfs View In Hierarchy

Turns BRANCH_TRANSPORT tuples into transports that point to branches.

This transport dispatch knows how branches are laid out on the disk in a particular "area". It doesn't know anything about the "hosted" or "mirrored" areas.

This is used directly by our internal services (puller and scanner).

Method __init__ Undocumented
Method makeTransport See ITransportDispatch.
Method _checkPath Raise an error if path_on_branch is not valid.
def __init__(self, base_transport):
Undocumented
def _checkPath(self, path_on_branch):
Raise an error if path_on_branch is not valid.

This allows us to enforce a certain level of policy about what goes into a branch directory on Launchpad. Specifically, we do not allow arbitrary files at the top-level, we only allow Bazaar control directories, and backups of same.

RaisesPermissionDeniedif path_on_branch is forbidden.
def makeTransport(self, transport_tuple):
See ITransportDispatch.
RaisesPermissionDeniedIf the path on the branch's transport is forbidden because it's not in ALLOWED_DIRECTORIES.
API Documentation for Launchpad, generated by pydoctor at 2022-06-16 00:00:12.