"It may help to understand human affairs to be clear that most of the great triumphs and tragedies of history are caused, not by people being fundamentally good or fundamentally bad, but by people being fundamentally people.
"Just when you thought that they were more malignant than ever Hell could be, they could occasionally show more grace than Heaven ever dreamed of. Often the same individual was involved."
"We will change. Because we can change, I know it. We may be weak, but we just have to be; if not, then we wouldn’t have any reason to grow, to get strong. I know that it may seem futile to you, but it’s not, because we are getting stronger with every step we take. You see I’m sure we can change! Because we’re weak, and because we die. We have to fight in order to live, and that’s what will make us strong."
This seems to be the best way to sum up the philosophies of the main characters in the 2003 anime version. They've all done things they aren't proud of, but seem to take a "humans are inherently flawed, but all we can do is the best we can" approach to their struggles.
Monster is largely about this. Tenma and Johan come to different conclusions from this premise.
While Sora No Woto ends on a fairly ambiguous note, Rio's ending narration works toward this trope.
Rio:Yeah... even if the world is going to end someday, until then, all that we have here with us is our future.
This is discussed in Black Butler, by Ciel and Sebastian shortly after Ciel has ordered the murder of a large number of children. Ciel degrades humans for being weak and fundamentally evil and curses himself for being one, but Sebastian notes that it is this constant struggle and their lofty goals that makes them interesting.
Puella Magi Madoka Magica is filled with flawed humans. One example being Kousuke, an annoying and clueless teen who angsts over his broken hand and takes his childhood friend's care and her "miracle" which fixes his hand for granted.
Of course, it isn't like he knew said childhood friend was responsible for the "miracle" in question. Because of the Masquerade.
Transmetropolitan. A lot. Especially towards the end, where Spider constantly drops that, despite being a bastard and some sort of weird figure for the masses, he's still human like everyone else, along with all the great and the extra-evil that humanity does on a daily basis.
This is one possible message of Watchmen: Because humans are flawed, our heroes will be as well, and thus our longing for perfect messianic figures to 'save us' is naive.
Fan Fiction
In Perfection Is Overrated, a large part of the plot involves the characters of Mai-HiME dealing with their personal problems, with the point being that by being imperfect and having to struggle against their flaws and improve themselves, they are stronger people than the "perfect" SUEs, who remain complacent.
This is a central theme in the Yellowstone continuity of The Conversion Bureau. Before the start of the adventure, Celestia warns Twilight Sparkle that humans are savage creatures. By the end, Twilight does admit that humans can be harsh, but only because Earth is far more unforgiving than Equestria. It's for this reason that she comes to the conclusion that while humans most certainly aren't perfect, they generally try to do good more often than not, and that the humans who are just plain evil are the exception. Celestia turns out to agree with her.
Film
This is one of the main themes (arguably the main theme) of Serenity. Even if the Pax had worked perfectly, it still would've been wrong to stifle the human emotional range for the sake of peace.
Also Mal points out our flaws (Sins) are what keeps humans from just laying down and dying.
This is also a fairly prominent theme of the movie's parent show, Firefly.
Equilibrium takes a similar approach. The entire reason for the plot was because human emotions were a flaw and the cause of 'man's inhumanity to man.' The ending, while portrayed positively, never exactly comes clear on whether restoring human emotion is a good thing.
Played very oddly and combined with Humans Are Special in Green Lantern; what makes humans so special is that we're willing to admit that we're flawed.
Literature
Used in Stranger in a Strange Land. Compared to Martians, Humans are a lot dumber, more violent, and less powerful. However, with a little wisdom from Mars courtesy of Michael, Humans can become immortal, psychic, spiritually peaceful and sexually polyamorous. It's a bit of an Author Tract, but not an unpleasant one.
This trope is one of the underlying themes of Good Omens.
In the Malazan Book Of The Fallen series, the Crippled God uses this as a premise for his cults of salvation. Unfortunately, rather than delivering the message that mortals can overcome their flaws to do good, the religion is a worship of suffering and degradation.
Robert J. Sawyer's The Neanderthal Parallax trilogy describes a parallel world in which Neanderthal man became the dominant species, and in almost every way homo sapiens compares badly. The Neanderthals live in harmony with nature, having a lower population and no pollution. Further they have no crime, violence or war, and (possible Author Tract) no religion. The effect is to highlight all of humanity's flaws by describing alternate-world humans that have none of them.
This is lampshaded by the Neanderthals literally having bred out of their own population all the negative traits by a program of enforced sterilizations over thousands of years (there is also one example involving domestic violence wherein this system is shown to utterly and totally fail).
Lords and Ladies uses this to contrast with Can't Argue with Elves. The elves end up losing because humans are flawed in comparison. Because humans die and change, they learn.
In Alan Dean Foster's The Damned trilogy humanity is discovered by an alliance of super-civilized alien species who are being forced to fight a war against their will. Compared to them we are portrayed as barely civilized, warlike, violence-crazed and brutish, and indeed our love for inflicting death and destruction makes us the perfect soldiers. However we're also capable of great things, and many humans try to control their instincts and strive for more than just being the alliance's grunts.
British statesman Lord Chesterfield in Letters To His Son: "In the mass of mankind, I fear, there is too great a majority of fools and, knaves; who, singly from their number, must to a certain degree be respected, though they are by no means respectable. And a man who will show every knave or fool that he thinks him such, will engage in a most ruinous war, against numbers much superior to those that he and his allies can bring into the field. Abhor a knave, and pity a fool in your heart; but let neither of them, unnecessarily, see that you do so." (letter 60)
Live-Action TV
Despite shouting "Humanity Is Superior!" humans in Farscape are most certainly not. One episode has aliens use Crichton's memory to simulate the possible outcome of revealing themselves to humanity in order to seek asylum. It doesn't end well. However, Crichton does become one of the most useful shipmates on Moya because of his ignorance and scientific training. It helps he was stir crazy at appropriate times.
Even more than that, it's Crichton's (and humanity's) persistence in the face of the toughest odds that set them apart from other species. It is viewed as a flaw by many, that humans are so ignorant they don't know when they're beat, but that characteristic is what kept Crichton and his shipmates alive for so long.
The Ancients (despite being humanity's progenitors) and the Nox, super advanced alien races in the Stargate Verse, seemed to hold the fact that humanity was flawed against the SG-C, seizing on the slightest issue to deliver some moralizing message or condemnation (sometimes appropriate to the situation, but often not). Made worse by the Ancients being a bunch of expletives anyway. By way of contrast the Asgard were both friendly and helpful despite knowing humanity was flawed, likely because unlike the other two they admitted they too had flaws. O'Neill once gave a heartfelt speech to the effect of 'we will mess up a lot as a species, but we are out here with you now and we are trying our best'. As he made it to the Asgard they were very approving.
Actually Thor (the Asgard military leader) is really a gigantic dick for a very long time. He's not openly hostile, though. And he eventually comes around and genuinely seems to like humans.
Seems to be the Doctor's view of humanity in Doctor Who, as Earth is his "favorite/pet planet" so to speak, but will turn around and ridicule humans about their shortcomings should the situation be extreme enough.
The Doctor: Human beings. You are amazing. Hah! Thank you. Zachary Cross Flane: Not at all. The Doctor: But apart from that you're completely mad. You should pack your bags, get back in that ship and fly for your lives.
This is how Jor-El views humans in Smallville, and his spirit bemoans that Clark Kent was raised by humans and thus, thinks like one. One of the only reasons why he did not give up on humanity completely, was because Jonathan Kent's father offered him food and shelter when he visited Earth in the 1960s (even super powered Kryptonians need to eat and sleep). The message on Kal-El's ship:
On this third planet from this star Sol, you will be a god among men. They are a flawed race. Rule them with strength, my son. That is where your greatness lies.
Only the A.I. Jor-El believes this, but not the real Jor-El. Reason being is that he created the A.I. version of himself without any of his own flaws.
For a while Brainiac masquerades as Clark's history professor. In one episode he goes into a spiel in class that lists various examples of humans' willingness to betray their friends. At the end of the episode, Clark admits humans aren't perfect and are certainly capable of greed and treachery. We're also capable of honor and compassion.
Lucifer in Supernatural believes this, calling us "broken, abortions."
Gabriel agrees, but gives us commendation for still trying. unlike most of his brothers.
A theme in the 1998 Merlin series, best shown when the Lady of the Lake tells Merlin, "It's human to make mistakes, Merlin, and part of you is human . . . the best part."
Person of Interest: Root believes this without believing there's anything redeemable about humans.
The Sopranos, in which selfishness, myopia and dysfunction are portrayed as the constants of the human condition.
Tabletop Games
This is the general feeling of New Horizon. Humans did some terrible things and had to leave Earth, but now that they're on a new planet they have a grand future!
Warhammer and Warhammer 40000: The Chaos gods are usually agreed to be the worst of Mankind's enemies. Unfortunately, since they are basically made of emotion (rage, love, desire and hope), humanity keeps fuelling them even when defeating their agents in the material plane.
In every iteration of Dungeons & Dragons before Third Edition, the distinguishing feature of Humans was that they had no distinguishing features. Every other race had a laundry list of special abilities. The tradeoff for this was that humans were the only race that could be any class (in fact, they were the only race that could be paladins at all) and could reach the maximum level in every class. The explanation generally given for this was that being generally unexceptional and shorter-lived than other races caused humans to be more ambitious and faster learners.
In Third through Fourth Edition, humans have been given special racial abilities, but they tend to make humans more versatile instead of more powerful (for example, in 4E, humans get +2 to any one stat of their choice, while every other race gets +2 to two stats, but one of them is fixed and the other is either also fixed or a choice of two stats).
System Shock: Lo-lo-look at you, hacker. A p-p-pathetic creature of meat and bone, panting and sweating as you r-run through my corridors-s. H-h-how can you challenge a perfect, immortal machine?
In many ways a staple of Shin Megami Tensei games. Despite all the bastardery that humans put you through in most games' plotlines, the pro-human endings that involve rejecting the supernatural powers that play with mankind are generally considered to be the most optimistic ones of the lot.
The same with Persona. Every major divine being is an Anthropomorphic Personification of something within the human heart (be it our good constructive parts (Philemon) or our fear of yet subconsious longing for death (Nyx). The Aesop of the franchise can pretty much be said to be that we humans are flawed but that we can overcome them.
In Resident Evil The Darkside Chronicles,Manuela comes to the conclusion that the ability to feel pain (mental/emotional pain at our mistakes, in particular) is what makes a person human, and that's a good thing, at least as opposed to being a super tough (but mindless and destructive) zombie monster.
While it first appears to set up a Humans Are The Real Monsters message, Eien no Aselia in the end opts for this. You have your instantly nice and understanding characters like Yuuto and Lesteena, your neutralish characters like Kouin and the populace at large and finally the evil people like Shun and Soma. The populace eventually grows to accept Yuuto and the spirits and see them as heroes, while Shun gets a decent motivation in a New Game Plus and a Sympathy for the Devil moment.
This is very apparent in L.A. Noire, what with the scores of less-than perfect people Cole encounters. This trope is even invoked by Roy Earle, of all people ("Everyone has their vices, even you, Cole."). Even Cole ends up having an affair and leaving his wife and kids, and even then, his past was hardly spotless.
This seems to be a major theme in The World Ends With You. Ultimately humans are flawed creatures obsessed with themselves until they clash with other people and their viewpoints, show with Neku's character growth. The act of having to clash itself suggests that only conflict causes humans to grow in any meaningful way.
In Dm C Devil May Cry, Mundus mocks Dante's desire to free humanity from demons by claiming that humans had freedom before he came, and in his words "They fought. They killed. They starved. I brought order." Vergil also believes this is true, and wishes to rule humanity alongside Dante after Mundus is defeated. He believes humans are like children that need to be protected from themselves. Dante counters this by pointing out that they would never have defeated Mundus without the aid of Kat, a human.
In Shin Super Robot Wars, Master Asia, who happens to be an agent of the Dug Government in this game, met Domon Kasshu's father Professor Kasshu and Char Aznable and figures the latter was where his problems started, coming short on the heels of the signing of the Luna Treaty that guarantees independence and sovereignty for the Earth, Moon, and space colonies. This treaty was enough to bring peace to the war-weary humans, but could not by itself remove the scars of the war. Char, who loved humanity more than anyone, also hated it more, having sacrificed numerous followers and taken many lives himself. Since he possessed vast influence and resources, Master Asia treated him as a representative of humanity. He was led to believe that humans were unstable, destructive beings, and decided to manipulate Kasshu to help nip any potential for trouble in the bud.
Web Comics
This brought up in Chapter 28 of Gunnerkrigg Court, where Kat the roboticist is depressed due to finding out that the creator of the Court's robots also cooked up a plan to kill a woman who didn't love him and his creations to protect the technologically-advanced court from the magical denizens of the Giliti Woods. Her irritation is interrupted after she finds a baby pigeon and takes it to her friend Paz, an animal lover who works with lab rats. Kat has a breakdown after learning all the things the Court does, but Paz reminds her that the Court is also capable of recognizing its flaws and changing them:
Paz: The Court isn't a big monster that does as it pleases. Es a collection of people, working to do what they think is right.
The Order of the Stick takes an interesting stance on this - when Roy dies, he's told that since he's mortal, it's not really reasonable to expect him to stay perfectly straight-and-narrow all the time, and making the effort is what's really important. This is repeated when he's allowed into the afterlife even though he didn't fulfill his father's Blood Oath; because he kept trying, he gets a pass, where his father consciously abandoned the quest, and is thus stuck in limbo until a member of his family defeats Xykon. Thus it's less "Humans suck because they are flawed" and more "Humans are flawed, but that's okay, because it doesn't have to define them."
Real Life
Go look up the life of your real life heroes. They will have a flaw or several. They can still be great men or women. They are also human. Human history is full of this.
There are some radical schools of thought claiming that all human flaws are only considered such due to societal pressure and should be cultivated rather than suppressed as they are the true and 'natural' traits of humanity.
This is heavily debated. Some religions, for instance Christianity, argue we are inherently flawed (to various degrees). This position is called Original Sin. But many philosophies and some religions disagree with this premise. Even within Christianity itself, this is debated.
Of course, it should also be pointed out that despite humanity's flawed and broken nature, all but the most utterly cynical branches of Christianity and other faiths and philosophies still point out that humanity inherently possesses value and virtue as well.
Of course, one can empirically observe many flaws in many humans. But this is a less strong claim than humans are inherently flawed.
Certain philosophies hold that humans would not be flawed if they would just return to some larger cosmic purpose that our ancestors abandoned. Several sages have even posited that we can progressively lose or overcome our flaws on the way back to said purpose.