branch.composePublicURL 500s if scheme is unknown

Bug #2002568 reported by Jelmer Vernooij
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Launchpad itself

Bug Description

  File "/home/jelmer/src/breezy/lp-anonymous/breezy/plugins/launchpad/", line 112, in _resolve_via_api
    return {'urls': [lp_branch.composePublicURL(scheme='bzr+ssh'), lp_branch.composePublicURL(scheme='https')]}
  File "/usr/lib/python3/dist-packages/lazr/restfulclient/", line 642, in __call__
    response, content = self.root._browser._request(
  File "/usr/lib/python3/dist-packages/lazr/restfulclient/", line 484, in _request
    raise error
lazr.restfulclient.errors.ServerError: HTTP Error 500: Internal Server Error
Response headers:
connection: close
content-length: 14
content-type: text/plain;charset=utf-8
date: Wed, 11 Jan 2023 18:25:46 GMT
server: gunicorn/19.8.1
status: 500
x-lazr-oopsid: OOPS-1e2edc7b84b1d29d16080ef63591190a
x-powered-by: Zope (, Python (
x-request-id: a8f424d0-176e-4bc6-bcb2-69d07f687711
x-vcs-revision: 0dc4a5528db5ce4d3653ad53877575d20a6f2d2f
Response body:

Tags: api lp-code
Guruprasad (lgp171188)
tags: added: api lp-code
Changed in launchpad:
status: New → Triaged
importance: Undecided → Low
Revision history for this message
Jürgen Gmach (jugmac00) wrote :

Do you have a fix in mind? Obviously, you want to have support for https.

Should there be a client side error (4xx) when an unknown scheme is requested?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.