But that understanding of America lets the country off the hook too easily. Viewing the aggressive and socially divisive elements of President Trump’s conservative populism as a deviation from the enlightened path of the nation romanticizes the American political tradition as being purely about cherished values such as liberty, freedom, equality, opportunity, representation, free markets, and justice. This view of America whitewashes away huge swaths of U.S. history in order to perpetuate the myth that at its essence America is a shining city on the hill.

But several generations of historians since the 1960s have shattered this myth. The regressive side of the Trump presidency is just as inscribed in the American political tradition as Ronald Reagan’s optimism or Barack Obama’s call for racial healing.

That is what makes moments such as the “shithole” nations comment so disturbing to see. The problem is not just what they say about President Trump, but what they say about America itself.

Nativism is nothing new. Each era when the nation liberalized its immigration policies to let more people into the country, the open doors have quickly been followed by a fierce backlash. The Chinese Exclusion Act of 1882 followed several years of brutal violence against Chinese workers. The influx of immigrants in the early 20th century from Eastern and Southern Europe ended after a decade of intense nativist attack that found respectability at the highest levels of power. Scholarly experts were praised when they promoted the pseudo-science of eugenics to demonstrate how the brains of the urban newcomers were inferior. Politicians warned of “race suicide” for Anglo-Saxons and even progressive reformers were desperate to Americanize the “foreigners” who were living in cities like New York and Chicago. Labor leaders in the burgeoning union movement, the historian Lizabeth Cohen wrote, were so deeply divided along ethnic and racial lines before the 1930s that effective organization and strike activity often proved impossible to sustain. In 1921 and 1924, Congress passed legislation that imposed a national quota system that limited the number of immigration visas to be granted to specific nationalities, particularly those regarded as inferior to “Anglo-Saxon” stock (such as Italians or Eastern Europeans), in order to restrict immigration that would remain in place until 1965.

Racism has always been in the American bloodstream. Of course, the national economy and its government were founded on the institution of slavery. The subjugation and importation of Africans to the American South was at the heart of the cotton trade. Americans fought an entire Civil War before slavery came to an end, and the nation subsequently experimented with a bold plan for Reconstruction, only to see noxious Jim Crow laws put into place that denied African Americans their newly won political rights and created a racially segregated economy that left much of the freed population living in conditions that were decisively separate and unequal. Notwithstanding the enormous progress born out of the civil-rights movement in the 1950s and 1960s, Americans have learned in recent years how little progress the nation has made on problems like institutional racism. Residential segregation continues, racism shapes every part of the American criminal-justice system, and American educational policies perpetually place significant portions of the population in a disadvantaged position simply because of the color of their skin. In 1968, the Kerner Commission warned that, “Our nation is moving toward two societies, one black, one white-separate and unequal,” and that "white society is deeply implicated in the ghetto.” That assessment could easily apply to today, where segregation and racial inequality remain lingering problems.