Power users may have experienced this situation before: They see a question that’s clearly a duplicate, so they hunt down the duplicate target and close the question. It’s only then that they realize that the question was improperly tagged, so they cannot hammer it, although they expected it to work.

This commonly happens to me personally when closing Python questions, which then fails when the question has a versioned Python tag but is missing the general Python tag which I have the gold badge for.

This userscript is made for exactly that situation and warns you when you are about to close a question as a duplicate, and you do not have a gold badge to hammer it. That way, you can check the tags first, and maybe get someone else to fix it, before you can hammer it.

Once you open the close dialog, the userscript tells you immediately whether you can hammer-close a question:

A hammer icon in red is displayed next to the “duplicate of…” close reason

If you go further, it gives you a more prominent warning:

A colored warning is displayed in the duplicate question selection view

If you do have a gold badge to hammer a question, this is confirmed with a green icon:

A hammer icon in green is displayed next to the “duplicate of…” close reason


Install and source

Changelog

  • 1.1.0: Add support for cloe review queue; adjust button label when hammering
  • 1.0.x: Compatibility improvements for Greasemonkey 4
  • 1.0.0: Initial release
  • It would be interesting to see a version of this script that implements the suggestion in this feature-request - i.e. add a gold-badge symbol, or the current hammer symbol, to the Vote to Close button that actually enacts the closure. – E.P. Jan 18 at 16:59
  • It would also be good for this script to apply to the close-vote review queue. – E.P. Jan 19 at 15:22
  • @E.P. I was very hesitant to add a button label change since the button is shared between all the close reasons, so I would have to change it back and forth. But, I’ve done that now anyway, so have fun with it. I also added support for the review queue. – poke Feb 10 at 1:59
  • The script incorrectly claims that I can hammer a question after I edit the tags (i.e. change python-3.x to python). Any chance you could update the script so it tracks the changes I make to the tags, and doesn't display an incorrect message? – Aran-Fey Apr 23 at 19:42
  • @Aran-Fey Uhhhh, I don’t think that will be possible nicely. There is nothing that can tell me that before clicking the button, so I would have to track this myself and that would be very messy. So I’ll have to decline that request; I don’t think it’s really worth the necessary effort :/ – poke Apr 23 at 19:46

You must log in to answer this question.

Browse other questions tagged .