/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/plugins/launchpad/lp_registration.py

  • Committer: Jelmer Vernooij
  • Date: 2018-11-16 23:19:12 UTC
  • mfrom: (7180 work)
  • mto: This revision was merged to the branch mainline in revision 7294.
  • Revision ID: jelmer@jelmer.uk-20181116231912-e043vpq22bdkxa6q
Merge trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
128
128
    registrant_email = None
129
129
    registrant_password = None
130
130
 
131
 
 
132
131
    def __init__(self, transport=None, lp_instance=None):
133
132
        """Construct a new service talking to the launchpad rpc server"""
134
133
        self._lp_instance = lp_instance
136
135
            uri_type = urlutils.parse_url(self.service_url)[0]
137
136
            transport = XMLRPCTransport(uri_type)
138
137
            transport.user_agent = 'Breezy/%s (xmlrpc/%s)' \
139
 
                    % (_breezy_version, xmlrpc_version)
 
138
                % (_breezy_version, xmlrpc_version)
140
139
        self.transport = transport
141
140
 
142
141
    @property
183
182
                # e.headers['location'] tells where to go and e.errcode==301; should
184
183
                # probably log something and retry on the new url.
185
184
                raise NotImplementedError("should resend request to %s, but this isn't implemented"
186
 
                        % e.headers.get('Location', 'NO-LOCATION-PRESENT'))
 
185
                                          % e.headers.get('Location', 'NO-LOCATION-PRESENT'))
187
186
            else:
188
187
                # we don't want to print the original message because its
189
188
                # str representation includes the plaintext password.
190
189
                # TODO: print more headers to help in tracking down failures
191
190
                raise errors.BzrError("xmlrpc protocol error connecting to %s: %s %s"
192
 
                        % (self.service_url, e.errcode, e.errmsg))
 
191
                                      % (self.service_url, e.errcode, e.errmsg))
193
192
        except socket.gaierror as e:
194
193
            raise errors.ConnectionError(
195
194
                "Could not resolve '%s'" % self.domain,