Broken ref breaks `tig --all`
setup
For some reason I had a broken tag in my git repository. That means I had an empty file .git/refs/tags/broken-tag. You can reproduce this issue by doing touch .git/refs/tags/broken-tag in any git repo; rm .git/refs/tags/broken-tag to clean up afterwards. (I tested all this with a branch in .git/refs/heads as well, same situation.)
problem
tig was able to run, also tig other-tag. But both tig broken-tag and tig --all fail with the error message tig: No revisions match the given arguments.. For the former that makes sense and I can try to find the root cause with that error, but for tig --all the error is misleading in my opinion.
solution
Would it be possible to improve the error message for tig --all? Or even better not make it a fatal error: git tag for example gives the error message warning: ignoring broken ref refs/tags/broken-tag but then still displays my other tags. tig --all could print a similar message and then still display the remaining good refs. Arguably if I specify a broken tag as an argument to tig it might be expected to fail hard, as it currently does.
tig versions
I tested this with tig version 2.5.5, 2.5.6 and 2.5.7. 2.5.6 and 2.5.7 behave as described here. 2.5.5 did not print any error messages or warnings and just displayed all remaining refs.