Short term games this can backfire, and long term vames, you still deal with Mary Sue, but yes, when making it clear you are 'placing the characters within their milieu' as you do this, it does help.
I do make it very, very clear that my games are lethal and dangerous. Even in a non-combat centric game (3 combats in 43 sessions), one PC lost an arm. and social circumstances are often NOT telegraphed, so I would add that in as a point not made in the post.
There was definitely the danger here that the players sided with the mystic sword disciples and tried to fight One-Armed Fiery Demon. That is always a danger though when you allow for things in the setting to be more powerful than the players can handle. I tried to clearly indicate that by having her use one of her more potent abilities on the sword disciples, but if the players pushed they could have ended up with a TPK for sure. However, I feel in that situation I had very much made it clear to them that she was an unbelievably powerful martial hero.
Long term Mary Sues are a problem, and something I am quite worried about. I've pretty much been striving to not have them in my games for years now (because of this experience:
HERE). However after reflection, I felt I had been overcorrecting this issue and limited NPCs in my campaigns too much. So this is an effort to restore NPCs that fit the game, while being mindful of what can happen if they become your favorites or you give them in game protection. I don't really have a problem killing off NPCs if they die in game, and I don't get hung up on them, so I feel this shouldn't become an issue (they have met One Armed Fiery Demon twice since their initial encounter with her, but in both those instances they sought her out).
I do think explaining stakes and consequences out of game is very important. I resorted to this method because I have been explaining consequences so long, and realized people don't always take such warnings seriously. Last campaign for example, people actually got lucky a number of times on the dice (enemies kept bringing them to the brink of death but not beyond it) and I believe they mistook that for me going soft on PCs, but on the 6th session or so there was a PC death, and I sensed that some were a bit surprised that it happened. I wanted to introduce a potentially dangerous situation to make it clear from the outside that these kinds of things were very much on the table.
There is a small detail to this encounter I left out of the stakes post. When the one of the players first walked into the tavern and saw her having a stand-off with the mystic sword disciples, she asked him "do you serve Lady White Blade". He said 'no', and she went on to attack the mystic sword disciples while leaving him alone. So the player realized right away had he chosen wrong, that her hostility would have been directed at him. This was the very first session, so while that was a big risk (and while it might have been possible for him to survive because he was Qi rank 1 and the mystic sword disciples were all only Qi rank 0 and he may have been able to parlay his way out of it) it could have ended very badly for him. My feeling was it would be better to illustrate this out of the gate, early on, before anyone got really attached to their character. That way players would really understand how much risk they were facing in this setting and act accordingly. I want these risks to be on the table, but I really want the players to understand that they are there so they can make their choices accordingly (a lot of times I still get the sense that players have come to expect the GM to save them in dangerous situations).
It is interesting that in a non-combat centric campaign you've had an arm loss in just three combats. But this sort of makes sense to me if you are using a particularly lethal system. The game I am running now, actually isn't that lethal because there are levels, so player are often taking on much weaker threats. But the core system itself doesn't have levels in most of its incarnations. So in terror network or crime network there is no difference in health between any character in the game. Everyone dies the same when they get shot. That kind of parity, makes for greater lethality. There is obviously skill to account for but everyone can take the same number of wounds and that makes any combat a big risk. What I find happens as a result is people tend to avoid combat unless it is really necessary, so the games usually become much less combat centric (a bit like real life, you don't go around beating people up all the time because there are real world consequences and dangers for that behavior).