Both TB take the same path through the code:
Module lazr.restful._resource, line 928, in __call__
result = self.do_POST()
Module lazr.restful._resource, line 765, in do_POST
return self.handleCustomPOST(operation_name)
Module lazr.restful._resource, line 1371, in handleCustomPOST
value = super(EntryResource, self).handleCustomPOST(operation_name)
Module lazr.restful._resource, line 749, in handleCustomPOST
return operation()
Module lazr.restful._operation, line 83, in __call__
response = self.call(**values)
Module lazr.restful.declarations, line 1210, in call
result = self._getMethod()(**params)
Module lp.code.model.branch, line 963, in requestMirror
raise BranchTypeError(self.unique_name)
BranchTypeError: ~bzr-explorer-dev/bzr-explorer/trunk
The code does this:
def requestMirror(self):
"""See `IBranch`."""
if self.branch_type in (BranchType.REMOTE, BranchType.HOSTED):
raise BranchTypeError(self.unique_name)
It looks like this method cannot be used a remote branch. This error should be converted to a HTTP code and the method documentation should make it clear the branch most be MIRRORED or IMPORTED.
Both TB take the same path through the code: _resource, line 928, in __call__ _resource, line 765, in do_POST omPOST( operation_ name) _resource, line 1371, in handleCustomPOST urce, self).handleCus tomPOST( operation_ name) _resource, line 749, in handleCustomPOST _operation, line 83, in __call__ declarations, line 1210, in call ()(**params) model.branch, line 963, in requestMirror (self.unique_ name) dev/bzr- explorer/ trunk
Module lazr.restful.
result = self.do_POST()
Module lazr.restful.
return self.handleCust
Module lazr.restful.
value = super(EntryReso
Module lazr.restful.
return operation()
Module lazr.restful.
response = self.call(**values)
Module lazr.restful.
result = self._getMethod
Module lp.code.
raise BranchTypeError
BranchTypeError: ~bzr-explorer-
The code does this:
def requestMirror( self): (self.unique_ name)
"""See `IBranch`."""
if self.branch_type in (BranchType.REMOTE, BranchType.HOSTED):
raise BranchTypeError
It looks like this method cannot be used a remote branch. This error should be converted to a HTTP code and the method documentation should make it clear the branch most be MIRRORED or IMPORTED.