This seems like a very old fashioned, pvp style of DM mentality. Int saves, fire immune foes, or archers all exist only because the DM wants them to exist. If you want to gatcha someone, that's fine, but don't pretend that's not what your doing. This being a problem at a table is generally created out of a disconnect between DMs who want to play grid-based-war-game and players who just want to be a fantasy archetype in a fantasy world, inspired by their favorite inspirational media or actual play. If they wanted to play grid-based-war-game, they probably would have created an appropriate character for that, if you let them know that's what was up.
I think you completely misunderstand. Specialization generally "works" against anything until the DM sets things up so that it doesn't. Fire Mage Guy generally does well against anything until you decide to make him helpless, same with melee only, bow only guy or even Heal Spells Only Guy. So my advice is, when you set up the negating scenario, think about what you're trying to achieve and what you're trying to teach or reinforce. If what you're trying to achieve with the scenario is or includes "Fire Mage Guy is a silly concept", maybe you should have told him that before he made Fire Mage Guy.
But if it flows naturally for the narrative of the game?
Lets try this:
Fire Mage Guy has been adventuring for a while and made an enemy of a cult. From encounters where there have been survivors the cult learns that FMG prefers fire.
Cult decides to kill FMG to prevent him from interfering anymore. They can either
1) cast
protection from elements: fire to increase their chances, or
2) just attack FMG and hope for the best.
In post 33 you said that if a PC specialises in something (fire in this case) and the DM has something that is resistant/immune/outside the specialisation, it is a "gotcha." The above scenario seems perfectly logical to me, i would expect it if playing FMG myself (and i would not need the DM to say:
in the course of the adventure someone may learn of your specialisation and try to counter it. I would expect it). I also don't see it as a grid-based-war game, and i don't see it as the DM thinking FMG is not appropriate for the game.
PCs can cast
protection from elements: fire to give them a better chance against a red dragon if they know they are going to be facing one (hhhhmmmm, I wonder, do you consider this a gotcha by the players v the DM?).
Is #1 (or the scenario) a gotcha, or can you as DM only do #2 (or not have the cult proactively try to stop FMG)?
The 2 bolded parts of the second quote is the first time I've seen where you have added that anything outside the specialisation isn't a PvP/DM gotcha/teach them a lesson not to specialise (honestly, if I've missed it which post is it in?).
Fire resist/immune v FMG isn't automatically PvP/DM gotcha/teach a lesson. It may be just a natural outcome of what has happened. The bolded+italicised implies you agree that not all instances are automatically a gotcha. Is that the case?
I would think that a DM gotcha would be having most enemies be fire immune v FMG even with no prior knowledge of FMG, but I haven't seen that touted here.