summaryrefslogtreecommitdiff
path: root/repo/fun.py
diff options
context:
space:
mode:
authorSebastian Thiel <byronimo@gmail.com>2010-11-24 22:53:24 +0100
committerSebastian Thiel <byronimo@gmail.com>2010-11-24 22:53:24 +0100
commitcf1d5bd4208514bab3e6ee523a70dff8176c8c80 (patch)
treed68f6529275838b9a962c4b76533e8445441af34 /repo/fun.py
parent3175b5b21194bcc8f4448abe0a03a98d3a4a1360 (diff)
parent7da101ba9a09a22a85c314a8909fd23468ae66f0 (diff)
downloadgitpython-cf1d5bd4208514bab3e6ee523a70dff8176c8c80.tar.gz
Merge branch 'reflogintegration'
Diffstat (limited to 'repo/fun.py')
-rw-r--r--repo/fun.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/repo/fun.py b/repo/fun.py
index c523a3e1..7a5984d3 100644
--- a/repo/fun.py
+++ b/repo/fun.py
@@ -112,7 +112,9 @@ def rev_parse(repo, rev):
for details
:note: Currently there is no access to the rev-log, rev-specs may only contain
topological tokens such ~ and ^.
- :raise BadObject: if the given revision could not be found"""
+ :raise BadObject: if the given revision could not be found
+ :raise ValueError: If rev couldn't be parsed
+ :raise IndexError: If invalid reflog index is specified"""
# colon search mode ?
if rev.startswith(':/'):
@@ -193,7 +195,7 @@ def rev_parse(repo, rev):
try:
entry = ref.log_entry(revlog_index)
except IndexError:
- raise BadObject("Invalid revlog index: %i" % revlog_index)
+ raise IndexError("Invalid revlog index: %i" % revlog_index)
#END handle index out of bound
obj = Object.new_from_sha(repo, hex_to_bin(entry.newhexsha))