I think the show ended exactly as it should have, staying as true to the characters as they possibly could
The problem is that they stayed true to the characters as they were written in season one -- and poor versions of their season one characters at that. Character development was always a problem with this show, in that the characters would take one step forward, two steps back. In this case they took TWO SEASONS BACK worth of steps, and to pretend the last couple seasons didn't happen was ridiculous and stupid.
From the Vulture recap:
I thought it was brave that they did him and not a side character like Eric or Jenny. It didn't make a ton of sense, but it probably made the most sense of anybody. They'd definitely come up with it a while ago and done their best in recent episodes to have it make sense.
No, Vulture recappers, they didn't come up with it awhile ago. This is from Carinna MacKenzie at Zap2it:
I spoke with executive producer Stephanie Savage and showrunner Sara Goodman at the beginning of this final season. The CW's promos promised to reveal the identity of Gossip Girl, and I was curious to know whether the writers had employed a plan for Gossip Girl's identity from the beginning of the series. "We've always had ideas," Savage said. "I think how far we were going to go with those ideas, how much we were going to make her into a character kind of shifted from season to season."
I'm guessing they talked about it through the course of the show, just jokingly -- like, "Hey, wouldn't it be funny if this person or this person was Gossip Girl?" But they came up with Dan being Gossip Girl at the beginning of season six and tried to make it make sense, although the way they wrote it, it appeared as though they came up with the idea while they were writing the finale.
Ugh. Such an epic fail of a show that started out with such promise.