Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
CLN: keyerror in versioneer error message
  • Loading branch information
Chris Bartak committed Nov 28, 2018
commit eb42b01f687438953cb4bb450205ff23b402bc1c
12 changes: 6 additions & 6 deletions pandas/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,14 +238,14 @@ def git_pieces_from_vcs(tag_prefix, root, verbose, run_command=run_command):
# tag
full_tag = mo.group(1)
if not full_tag.startswith(tag_prefix):
fmt = ("tag '{full_tag}' doesn't start with prefix "
"'{tag_prefix}'")
msg = fmt.format(full_tag=full_tag, tag_prefix=tag_prefix)
if verbose:
fmt = "tag '{full_tag}' doesn't start with prefix " \
"'{tag_prefix}'"
print(fmt.format(full_tag=full_tag, tag_prefix=tag_prefix))
pieces["error"] = ("tag '{full_tag}' doesn't start with "
"prefix '{tag_prefix}'".format(
full_tag, tag_prefix))
print(msg)
pieces["error"] = msg
return pieces

pieces["closest-tag"] = full_tag[len(tag_prefix):]

# distance: number of commits since tag
Expand Down