It pains me to write this, but the time has come for “The Simpsons” to retire.

Not just because of ongoing controversy over characters some contend are racist — controversy made clear in comedian Hari Kondabolu’s documentary “The Problem With Apu” — but also because of the ham-fisted, insensitive responses by the writers and show creator to such criticism.

The Simpsons” entered the TV record book last week with its 636th episode, passing “Gunsmoke” for the most episodes of any show in prime-time TV history.

But wisdom has not come with age. The world has changed considerably since the show premiered in December 1989. In 1990, for example, “The Simpsons” went head-to-head with the wildly popular “Cosby Show”; it’s still on the air, while Bill Cosby has been convicted of sexual assault.

Times have changed, but “The Simpsons” has not. In response to complaints that Kwik-E Mart owner Apu has made Americans of South Asian descent subject to taunting for decades, the response from the show’s producers is — this is how the show has always been.

The fact that racist stereotypes are less acceptable than they were three decades ago is not a bad thing. And “The Simpsons” is running the risk of becoming the 21st-century equivalent to Charlie Chan, “Amos ’n’ Andy” and “Song of the South.”

(Photo: Frank Micelotta/Fox) "Simpsons" creator Matt Groening holds up a drawing of Apu.

Simpson” creator Matt Groening made things worse with his unbelievably insensitive comments to USA Today. Asked if he had any thoughts on the Apu controversy, Groening replied, “Not really. I’m proud of what we do on the show. And I think it’s a time in our culture where people love to pretend they’re offended.”

Groening is certainly entitled to disagree with the show’s critics, but to dismiss them so condescendingly shows an appalling lack of empathy and character.

Perhaps if Groening had bothered to watch “The Problem With Apu,” he’d know it’s a sensitive and humorous exploration of the problem. But after raking in untold millions of dollars from “The Simpsons” franchise, he’s just too privileged to acknowledge that some people are genuinely wounded by Apu.

Producer Adi Shankar (“Dredd,” “A Walking Among the Tombstones”) told Indiewire that Apu “is an inaccurate, fabricated archetype that was created by ‘The Simpsons’ and carved into the American consciousness through blunt force over 30 years.”

Clearly, he’s not pretending to be offended.

It’s true that Apu is one of many racial or ethnic stereotypes on the show. But that’s not a defense, it’s a further indictment.

And, for writers who take pride in being equal-opportunity offenders, they sure are thin-skinned. In a recent episode, they included a scene in which Lisa Simpson sat next to a picture of Apu and spoke directly to the audience: “Something that started decades ago and was applauded and inoffensive is now politically incorrect. What can you do?”

Seriously? What can you do? You can learn. You can grow. You can change. You can listen to someone outside the bubble of your predominantly white, male writing staff.

In this April 24, 2018 photo released by CBS, actor Hank Azaria, left appears with host Stephen Colbert on "The Late Show with Stephen Colbert." (Scott Kowalchyk/CBS via AP)

Hank Azaria, the white actor who voices Apu and has minimized the problem in the past, during a recent appearance on “The Late Show” called for the inclusion of South Asian writers. He told host Stephen Colbert that he is “perfectly willing and happy to step aside. … It not only makes sense, but it just feels like the right thing to do.”

He criticized the show for initial responses to “The Problem With Apu.”

That’s definitely not the message that I want to send,” he said. “My eyes have been opened. And I think the most important thing is we have to listen to South Asian people, Indian people in this country, when they talk about what they feel and how they think about this character, and what their American experience of it has been.”

Maybe Azaria should have a chat with Groening.

I’ve always been a huge “Simpsons” fan. I have “Simpsons” memorabilia around my house. I’ve defended the show repeatedly.

And, no, it’s not going away soon. It’s already been renewed for two more seasons.

I just hope the producers and writing staff realize it’s 2018, not 1989.