# gitk bug: annotated tag displays as a lightweight tag when branch of the same name is on the same commit

1 messages from 2010-05-05 to 2010-05-05. Participants: David Holmer.
Thread: https://gitlist.dev/t/23709

## David Holmer, 2010-05-05 14:17

Subject: gitk bug: annotated tag displays as a lightweight tag when branch of the same name is on the same commit
Message-ID: <loom.20100505T155543-396@post.gmane.org>
URL: https://gitlist.dev/e/loom.20100505T155543-396%40post.gmane.org

```
I found an edge case bug in the display behavior of gitk. I encountered it while
working in a repository where we make branches with a name like "1.0.3" and
create an annotated tag "1.0.3" when everything is ready on that branch. In the
process of scripting some of this, I thought I was not creating the annotated
tags correctly because when I'd look at them in gitk, they were showing up as
lightweight tags. However I noticed that "git describe" was showing the tag name
correctly, and thus the issue was in gitk.

The bug can be simply reproduced by the following sequence of commands:

git init
touch test
git add test
git commit -m "commit message"
git tag -am "annotated tag message" master
gitk

The master tag is displayed in gitk pane as a lightweight tag rather than an
annotated tag:

Tag: master
Id:  5b0a763ec5791da4981f14ff5f6ef6384117945c

However if I move the master branch on to a new commit or rename it:

git branch -m renamed

Then the tag is correctly displayed by gitk as an annotated tag:

object 5b0a763ec5791da4981f14ff5f6ef6384117945c
type commit
tag master
tagger David Holmer <xxxxx@xxxxxxxxxxx> 1273068181 -0400

annotated tag message

Thank you,
David

```
