FS#34650 - VCS mechanism is unable to access Launchpad projects via Bazaar because of URL parsing

Attached to Project: Pacman
Opened by Adam Reichold (adamreichold) - Sunday, 07 April 2013, 07:28 GMT
Last edited by Allan McRae (Allan) - Tuesday, 16 April 2013, 02:02 GMT
Task Type Bug Report
Category makepkg
Status Closed
Assigned To No-one
Architecture All
Severity Low
Priority Normal
Reported Version 4.1.0
Due in Version 4.1.1
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

I am trying to update the "qpdfview-bzr" package to use pacman 4.1's VCS mechanism but it does not accept the Bazaar/Launchpad URL as such and for example exits with "ERROR: bzr+lp:qpdfview was not found in the build directory and is not a URL." if I try "source=(bzr+lp:qpdfview)". I also tried the more verbose "source=(trunk::bzr+bzr+ssh://bazaar.launchpad.net/~adamreichold/qpdfview/trunk)" but this fails as makepkg tries to access "ssh://bazaar.launchpad..." which is not a valid Bazaar URL. What seems close to working is "source=(trunk::bzr+bzr://bazaar.launchpad.net/~adamreichold/qpdfview/trunk)" but the code repositories on Launchpad are accessible via SSH only. I guess this has something to do with how URL are detected and parsed by pacman.
This task depends upon

Closed by  Allan McRae (Allan)
Tuesday, 16 April 2013, 02:02 GMT
Reason for closing:  Fixed
Additional comments about closing:  git commit 2bf2700b
Comment by Maxime Gauduin (Alucryd) - Sunday, 07 April 2013, 09:42 GMT
For the moment, only one kind of URL is accepted in the source array to allow for updating. You will have to use the URL printed by either 'bzr info' or 'bzr config parent_location' when ran inside the downloaded repo. Here is an example of what the correct lightdm URL looks like: "bzr+http://bazaar.launchpad.net/~lightdm-team/lightdm/trunk/".
Comment by Adam Reichold (adamreichold) - Sunday, 07 April 2013, 10:53 GMT
Using "bzr+http://bazaar.launchpad.net/~adamreichold/qpdfview/trunk" does indeed work for downloading even though "bzr info" states "bzr+ssh://bazaar.launchpad.net/~adamreichold/qpdfview/trunk" as the parent branch. Thanks for your help! Using the PKGBUILD of lightdm-bzr as a template, I was able to get it to work. The longer URL are rather small inconvenience, so I suppose this is bug is invalid then.
Comment by Adam Reichold (adamreichold) - Sunday, 07 April 2013, 10:56 GMT
(By the way, if someone ever stumbles on this report again: The trailing slash seems rather important because the parent branch will not be detected correctly without it, i.e. "bzr+http://bazaar.launchpad.net/~adamreichold/qpdfview/trunk/" works while "bzr+http://bazaar.launchpad.net/~adamreichold/qpdfview/trunk" does not.)
Comment by Maxime Gauduin (Alucryd) - Sunday, 07 April 2013, 12:33 GMT
Oh, what you said about bzr info is interesting, I didn't check its output before using the "correct" URLs, this might just be what we're looking for to support every other URLs. I'll look into it.
Comment by Adam Reichold (adamreichold) - Sunday, 07 April 2013, 12:48 GMT
After thinking about it a bit, it is probably not good to ship a public package using the SSH transport for Bazaar since this is authenticated with Launchpad, i.e. you need an account with a registered SSH public key. Hence the HTTP transport seems the only viable choice anyway.
Comment by Maxime Gauduin (Alucryd) - Sunday, 07 April 2013, 12:57 GMT
Hmm, 'bzr info' and 'bzr config parent_location' give me the same output if I use an lp: or an http:// URL (also using lp: in the source array does not work at all as you said). Maybe branching using ssh gives different results, unfortunately I don't have ssh access to any bzr repo, but you're right, using http is best anyway.

Loading...