I think you hit the nail on the head when you mentioned the uncertainty these productions face from season to season.
It would be a difficult and heartbreaking task to write the end of your own job. Thinking about it that way it kind of makes sense that the quality can drop off a cliff when they know the end is near.
Not to mention wrapping up multi seasonal plot lines that you've planned on continuing. That alone would be a huge problem.
I think The Boys on Amazon Prime kinda' touched on this in the final episodes leading up to the finale. There's this character that serves as a 'self insert' for the show runner. This character is a writer for tv shows, and in one instance he talks about how impossible it is to adequately tie up and end the various plot lines leading up to a series finale, and that finales are always disappointing...
It was a very poorly done 4th wall break, practically warning the viewer that a lackluster and disappointing finale was about to come their way.
They should never have attempted meta commentary... It was seriously cringe worthy.
The point they make though I think carries weight.
It takes a level of talent rarely seen to end a show to the same standard it had begun with.
Another good example is Star Trek: Voyager, that had such a rushed and clunky finish. A bad end to an otherwise amazing show.
Now that I think about it, the opposite can also happen. Shows can start off poorly, but end amazingly.
Like star trek: ds9, Babylon 5, or even Stargate.
The first seasons of those shows were.. mid at best, but damn did they have a hell of an ending.
RE: Why do some successful TV series (sometimes) have bad endings?