[PATCH] Missing revision spec for "bzr version"

John A Meinel john at arbash-meinel.com
Sat Sep 17 04:35:50 BST 2005

Lalo Martins wrote:
> Heh, how ironic.  I broke one of my own first contributions.
> /me blushes and goes hide somewhere
> And so says John A Meinel on 16/09/05 22:49...
>>In the latest bzr.dev code, "bzr version" no longer prints out the
>>revision information.
>>The problem is that __init__.py was changed and get_bzr_revision() did
>>not return the right value.
> ...
>>-        branch = Branch.open(__path__[0])
>>+        import os
>>+        branch = Branch.open(os.path.dirname(__path__[0]))
> Nope, not quite.  __path__ was always bzrlib.  The right fix is:
> -        branch = Branch.open(__path__[0])
> +        branch = Branch.open_containing(__path__[0])

I disagree. Because if I have:


Basically, I have something like my home directory automatically
versioned, but I'm using the tarball bzr.dev so I don't have the history.

In that case, your code would find my working directory as the branch,
which would cause it to report the wrong revision.

This was discussed in the past, I'm not sure if you saw the discussion.


> best,
>                                                Lalo Martins
> --
>       So many of our dreams at first seem impossible,
>        then they seem improbable, and then, when we
>        summon the will, they soon become inevitable.
> --
> http://www.exoweb.net/                  mailto:lalo at exoweb.net
> GNU: never give up freedom                 http://www.gnu.org/

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 253 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20050916/44c1a9b5/attachment.pgp 

More information about the bazaar mailing list