It's the Lavender Scare by David K. Johnson. See if your library has it! It's kinda expensive on Amazon. It takes place in Washington DC, in 1940s-60s.
I read the hell out of that book and it's one of the ones I continually have thought about since then. I had to keep checking the copyright page and years to make sure what was happening in 1954 and not a handful of decades later, lol.
https://www.amazon.com/Lavender-Scare-Persecution-Lesbians-Government/dp/0226401901