First off, if they extend a qualifying offer, they get a top 40 pick. That is not nothing.
also, teams lose players to free agency all the time. They’ll be getting 2 years of production for him, not nothing.
If they trade him, the rotation is league average at best. Trading away a chance at playoff wins is not worth the couple of average prospects they’d get for a rental piece. Trading Gray regardless is such a ridiculous take, I’m sorry but it is.