I don't think so. Javert had his flaws. He seemed unable to empathize with the criminals he pursued, unable to accept that they can be "a man, no worse than any man". He called them "garbage" and "from the gutter". If he had been a Sympathetic Inspector Antagonist, it might have made the fundamental tragedy more complete, but maybe that would have been too miserable even for a book called Les Miserables
But at his core, Javert is a police inspector. No more, no less. He catches criminals. He's very good at it. He does nothing beyond what his role as a police inspector demands of him; at times he is more of an avatar of Law than a human individual. Javert deserves death if and only if all policemen deserve death, if and only if the police force as an institution must be excised from society as a malign cancer.
Was Javert evil to work for an evil regime? "Evil regime" risks making things sound too black and white. Restoration-era France was far from optimal, but neither was it tyrannical; it was a constitutional monarchy where citizens elected the legislature and enjoyed the usual array of civil rights. The laws were made by much the same process as anywhere else in the world, and with much the same results. We deal in overly simple concepts like "evil regime" at our peril when there are so many sympathetic, democratic governments that do great good with one hand and great evil with the other. And to condemn Javert to death is to condemn most of history's civil servants.
Or was Javert evil for refusing to show mercy, for not giving Valjean a nod and a wink once he realized that Jean was basically a good guy? Here, too, I know what the Inspector would say in his own defense. "A government of laws and not of men" is fair to everyone; ideally those who falter and those who fall must pay the price, whether they are man or woman, black or white, sympathetic or unsympathetic. If we gave police officers carte blanche to arrest the people they felt like arresting and release the people they felt like releasing, then why bother having laws at all? One might as well just tell the police "If you see someone doing something that's, y'know, bad, then send them to prison."
Maybe he would say there is in a sense no such thing as mercy. There is only replacing one law with a second law. Suppose the law demanded a harsh prison sentence for anyone who steals more than ten francs. Javert catches Valjean stealing something worth eleven francs, surely an opportunity for mercy if ever there was one. But if Javert lets him off and privately resolves not to prosecute thefts of less than twenty francs, one day he's going to encounter someone stealing only twenty-one francs and feel tempted to have mercy upon them; they are after all only one franc above his new limit.
And if he lets that second thief go, if he shows mercy and ups the limit to thirty francs, it's easy to see that he will never arrest anyone. But if he arrests that thief, he is following his new "twenty francs or more" law with all the severity of an Old Testament prophet. His standard may include a different number than that of a more lax inspector, but his application of it is just the same.
So if you are going to show no mercy for people who break a rule, asks Javert, why not make it the rule that's on the books, that everyone knows about, and that society has entrusted you to uphold? Why not show no mercy for that rule, instead of a weasel rule like "Oh, if you're within ten percent of the amount on the books I'll let you off, but no more"?
And yet the argument, so elegant, so simple, leads to Inspector Javert condemning Valjean to terrible suffering for a completely disproportionate crime: as Valjean put it, "they chained me and left me for dead - just for stealing a mouthful of bread." Which was not just a minor crime, but perhaps even a heroic act: he did it to save the life of his starving nephew, at great risk to himself. And it destroys his life, and in the end it leads to Javert himself suffering a moral conflict so intense that he breaks down and takes a long walk off a short bridge.
Mamet defines a tragedy as a human interaction where both antagonists are arguably in the right. Valjean was arguably in the right to steal a loaf of bread to save his starving nephew, and to want mercy for the extenuating circumstances of his case. Javert was wrong to divorce his work from understanding and compassion, but he was still arguably in the right to enforce the law just as written and defend the codes that make society possible Nevertheless in the end their conflict lands Valjean a miserable prison sentence and drives Javert to suicide.
In philosophical traditions from Kant to Russell, a paradox has always been a sign that your foundations are wrong. I would resolve the moral paradox of Valjean and Javert not by condemning either of them, but by condemning the foundation beneath them both, the corrupt society which forces two virtues into opposition. 19th century France was not tyrannical, but neither was it optimal, and wherever a society is flawed good people can be forced into conflict with one another based on the roles they play.
Hugo wrote allegorically about justice and mercy, but his setting and his theme was Revolution. In a world where good and the law, justice and mercy, are diametrically opposed, sometimes revolution is the only unambiguously good action you can take. You can be a violent revolutionary like Enjolras or a peaceful revolutionary working within the system like General Lamarque, and historically the latter have had better results, but in the end the only solution to good people being destroyed by the law is to rise up in an attempt to yoke the law to the service of goodness.
It was the failure of Enjolras and his comrades to remake the world that forced the story to end as a tragedy. When society is unjust, there will always come a time when the rare and magical power of goodness-beyond-obligation brings those who possess it into conflict with the law, and then the law will crush them, those whom we can least afford to lose. Someone suffers, someone is sent to jail, someone commits suicide, someone's life is needlessly destroyed. Just for stealing a mouthful of bread.
I didn't know Aaron Swartz very well. He hung around Less Wrong for about six months. I read some of his stuff. I think he read some of mine. But he was a brilliant programmer who had a major impact on my life and the lives of many other people through some of his inventions like Reddit and RSS, as well as through his political activism and his support of efficient charity.
Aaron was one of those rare people who understood the good-beyond-obligation, who pursued ideals no one would have faulted him for abandoning even at great personal cost to his own safety and reputation. Angry at the power of "scientific gatekeeper" organizations like Elsevier and JSTOR to deny the public access to the scientific data that they funded or even collected, he launched an ambitious scheme to hack into JSTOR's database and make a big chunk of the total scientific production of humanity available to anyone who wanted it, free of charge, on BitTorrent. It was brilliant, ambitious, and totally illegal; he got caught halfway through and the government decided to throw the book at him. He got thirteen counts of felony with a penalty of up to thirty-five years in prison. For reasons which are impossible to know but easy to guess, Aaron committed suicide Friday, leaving all his money to charity. One of those brilliant and compassionate people the world can least afford to lose at a moment like this is lost to us. Just for stealing a mouthful of bread.
There is still a society that lets law and goodness work at cross-purposes. There are still revolutionaries and they still die for their presumption, leaving behind only a memory and an inspiration to those who follow. And still tragedies.
From the table in the corner
They could see a world reborn
And they rose with voices ringing
I can hear them now!
The very words that they had sung
Became their last communion
On the lonely barricade at dawn.
Oh my friends, my friends, don't ask me
What your sacrifice was for
Empty chairs at empty tables
Where my friends will meet no more