151
151
headers = {"Content-Type": "application/x-git-upload-pack-request"}
152
152
req = Request('GET', url, accepted_errors=[200, 403, 404, 405],
154
(scheme, user, password, host, port, path) = urlutils.parse_url(req.get_full_url())
155
156
# GitHub requires we lie. https://github.com/dulwich/dulwich/issues/562
156
157
req.add_header("User-Agent", user_agent_for_github())
158
159
# Don't attempt Git probes against bazaar.launchpad.net; pad.lv/1744830
159
160
raise bzr_errors.NotBranchError(transport.base)
160
161
req.follow_redirections = True