ATSM specs for Diesel say it's good for 1 year.
If it smells like rotten eggs, or doesn't look right, it's been in the tank too long.
If it's older than 1 year, it can pretty well be usable, You might want to consider getting the fuel "Polished" meaning, getting it filtered and processed.
I know marinas tend to do it, but outside of that, I'd have no idea where to get it done.
EDIT: IF it's dyed, like they do for Kerosene, you might have an issue getting any of this done.