{"issue":{"state":"open","created_at":"2011-12-04T07:07:48Z","updated_at":"2011-12-04T07:07:48Z","comments":0,"user":{"gravatar_id":"a5d51408463c2a64e3652c64df488eb8","id":228171,"url":"https://api.github.com/users/mstump","avatar_url":"https://secure.gravatar.com/avatar/a5d51408463c2a64e3652c64df488eb8?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","login":"mstump"},"body":"I'm using version 2.1.1\r\n\r\nacts-as-taggable-on is creating multiple tags with the same name.  For example I had 4 tags all with the name 'Debian'.  Often the same object is tagged once by each of these duplicates so one of my objects may have 4 'Debian' tags, but each tag maps back to a tag with a different ID with the same name.\r\n\r\nThe SQL query below reveals that on my system I have 17 tags that have at least one duplicate.\r\n\r\nselect distinct name from tags where name in (select name from tags group by name having count(*) > 1);\"\r\n\r\nI can't reproduce it in test, but it's happening in production.  It doesn't happen very often, but my database has over 6m tagged objects most of which are visited nightly, and it produced these 16 duplicates tags over the course of about 2 months.\r\n\r\nMy code won't add a tag to an object if it's already part of the tag_list collection, and the tags associated with an object are fairly stable so I'm guessing it happens on object creation?","assignee":null,"id":2440969,"labels":[],"pull_request":{"patch_url":null,"html_url":null,"diff_url":null},"number":206,"title":"Multiple tags with the same name are being created","html_url":"https://github.com/mbleigh/acts-as-taggable-on/issues/206","closed_at":null,"url":"https://api.github.com/repos/mbleigh/acts-as-taggable-on/issues/206","milestone":null},"action":"opened"}