Traditionally in US schools you were taught that applying "they" to a non-plural was outright incorrect—as in, a student would lose points if used that way on homework growing up.
When you don't know the gender, however, it is really convenient to use "they", so albeit the incorrect form, with time it started to take hold. Lately gender politics have acted as a catalyst as some people outright tell you they prefer that you use the "they/them" pronouns. Since a lot of folks are already comfortable using they/them, it works.
A different tactic is to just substitute something else entirely. Books like On Writing encourage young writers to avoid the situation and try to substitute other words rather than use "they" or just default to "he." An example might be using the word "writer". For example the books recommends instead of using "He should learn to use semicolons only when absolutely necessary" use "The writer should learn to use..." instead.
I think the latter method is harder in non-formal threads like this. "The imprisoned already has served 7 years" works, but comes across as really impersonal.
"They" is the only option when you don't know the gender of the person but it is still valid even if you do know the gender, though less commonly used in that situation
From a grammatical perspective it should be noted that "they" is plural. It is gender-neutral, but should only be used when referring to multiple people. The correct gender-neutral singular pronoun is "he or she".
When you don't know the gender, however, it is really convenient to use "they", so albeit the incorrect form, with time it started to take hold. Lately gender politics have acted as a catalyst as some people outright tell you they prefer that you use the "they/them" pronouns. Since a lot of folks are already comfortable using they/them, it works.
A different tactic is to just substitute something else entirely. Books like On Writing encourage young writers to avoid the situation and try to substitute other words rather than use "they" or just default to "he." An example might be using the word "writer". For example the books recommends instead of using "He should learn to use semicolons only when absolutely necessary" use "The writer should learn to use..." instead.
I think the latter method is harder in non-formal threads like this. "The imprisoned already has served 7 years" works, but comes across as really impersonal.