It's very common in modules that I've read - and on the whole I think it makes them bad modules.
As a player, if the only reason I'm doing XYZ in the game is because it's some sort of fetch/McGuffin quest set by the patron, and then it turns out it was all pointless because the patron was a traitor all along, why did I bother with that stuff?
See below...
In my view, there is a significant difference here between (i) a player choosing to have a PC who has fallen out with a patron, or has had the scales fall from his/her eyes, (ii) a player suffering an adverse consequence (like betrayal) as a consequence of failure in action resolution, and (iii) the GM just deciding, by fiat, that the PCs lose. I'm not interested in spending multiple sessions playing a chump or patsy for the amusement of the GM.
You're looking at the short game, the here-and-now frustration at being duped; and ignoring the long game.
The real purpose of the McGuffin quest was never to recover the McGuffin (though you just did, and made the patron more powerful as a result), it was to set the patron up as a long-term villain for the campaign. At least, that was the case in the two early-campaign instances I can think of where I've done pretty much just this. (one wasn't very successful, that storyline petered out in favour of other things before long; the other worked really well and gave me about a 15-adventure story arc over three years, woven between other adventures and sideshows)
I was in the games I posted about; you were not. I can tell you they were not interesting as storytelling events.
More generally, I don't play RPGs to tell stories or be told them. I play RPGs to create a shared fiction with my friends.
And that shared fiction grows into - you guessed it - a story!
I'm not the least bit interested in playing the GM's story, and I hope I've made that clear. As I said, if the GM wants me to read his/her story s/he can fax it to me!
Assuming of course that the story the GM faxes you is the same as the story that got played out.
It occurs to me that'd be an interesting experiment sometime: as GM, write out in point form the story you've got in mind for the campaign and seal it in an envelope. Then play the campaign as usual, without undue railroading, and see where it goes. Afterwards, open up the envelope and compare the results. You might be pleasantly surprised.
side note: a few weeks ago I stumbled over my original storyboard for my current campaign, written about 11 years ago; and other than a few specific adventures and modules it sure doesn't bear much resemblance to what's actually been played out!
I want to play my PC, engaging situations the GM presents that are interesting and exciting and relevant, and finding out what happens. My Burning Wheel GM has only ever GMed a handful of sessions - it's his first time as GM - but so far is doing a better job than plenty of far more experienced GMs that I've played with.
I want to play my PC too; but I also want to be able to look ahead and around beyond the here-and-now, see how things are developing in the setting, and make plans for what I and-or the party can do to influence these developments either now or in the future.
For example, were I a player in that McGuffin-for-the-patron game I'd probably be thinking (in character!) while playing that adventure about things like "what will I do with my share of the loot and reward if this goes well?", "wonder if this patron has other jobs for us?", etc., and also "what will I or we do if the patron heel-turns on us or doesn't pay us?" and "what's our next move if we don't find the McGuffin or - more likely - find it and then break it?".
Long-range planning. Useful pastime.
Lan-"of course any long-range planning assumes survival of the current adventure, but hey..."-efan