He is always a dark shade of gray, and displays flashing behavior a lot. I’ve had him for months and none of my other fish seem bothered so I don’t know when he is irritated specifically. It is in a 30g tank (don’t worry it’s not even the size of my palm yet) so I don’t think it’s an issue with the tank size
A palm-sized convict is very large for a 30 gallon (unless you have really tiny hands?) Convicts need lots of swimming space, water movement and high oxygenation. Even then, their thriving long term in captivity is kind of rare. They will turn dusky colored when unhappy. However, the flashing is a symptom of a skin infection (usually flukes) and that will cause the fish to turn dusky as well.
I'd say this is likely a chronic fluke infection. Hyposalinity or praziquantel would be the treatments of choice, but hypo cannot be used in tanks with invertebrates present.
Here is my write-up on prazi:
https://www.reef2reef.com/threads/dosing-praziquantel-pzq.1105700/
Here is the write-up on hyposalinity:
https://www.reef2reef.com/threads/hyposalinity.880546/