Revision argument causes no matches to be found
Bug #667443 reported by
Ben Jansen
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
bzr-grep |
In Progress
|
Medium
|
Parth Malwankar |
Bug Description
If I specify a revision, bzr-grep outputs no results. For example, using the branch at lp:bzr-diff-revid, you see that without '-r' grep locates on instance of 'getattr' in the working tree. However, adding "-r -1" (for head) causes no match to be found. I've experimented and it appears that all values for the revision option cause matches to be missed.
aogail@
aogail@
__init__.py: if getattr(tree, 'get_revision_id', None) is None:
aogail@
aogail@
To post a comment you must log in.
I can reproduce this.
Seems like the 'getattr' is found if we specify the file on the command line but for some reason its missed when we don't do that.
[bzr-diff-revid]% bzr cat -r -1 __init__.py | grep getattr
if getattr(tree, 'get_revision_id', None) is None:
[bzr-diff-revid]% bzr grep -r -1 getattr
[bzr-diff-revid]% bzr grep -r -2 getattr
[bzr-diff-revid]% bzr grep -r -2 getattr __init__.py
__init__.py~3: if getattr(tree, 'get_revision_id', None) is None:
[bzr-diff-revid]% bzr grep -r -1 getattr __init__.py
__init__.py~4: if getattr(tree, 'get_revision_id', None) is None:
[bzr-diff-revid]% bzr grep -r last:1 getattr __init__.py
__init__.py~4: if getattr(tree, 'get_revision_id', None) is None:
[bzr-diff-revid]% bzr grep -r last:1 getattr
[bzr-diff-revid]%