James Purefoy and Michael K Williams in "Hap and Leonard"

SundanceTV announced today that their acclaimed anthology series “Hap and Leonard” would receive a third season in 2018. Based on Joe R. Lansdale’s book series, the show follows an idiosyncratic odd couple — the lifelong best-friend duo of Hap Collins (James Purefoy), a straight white ex-con, and Leonard Price (Michael Kenneth Williams of “The Wire” fame), a black Vietnam vet who is also gay — through the twist and turns of a different mystery every season.

The first two seasons of “Hap and Leonard” drew acclaim not only for their darkly comic “Southern noir” mystery stories but also for how the show approaches race and masculinity through the lens of the friendship between the two men.

Salon’s TV critic Melanie McFarland describes season 2’s story as “a jumbled mystery involving multiple disappearances of black boys, a local police force unmotivated to find them, and the struggles of the falsely accused — Leonard, in this case” and writes in her season 2 review that the show uses Leonard’s interactions with the law to illustrate how little has changed in law enforcement bias and how prejudice affects the American justice system since the show’s setting in the late 1980s.

It’s not as if the first season of “Hap and Leonard” ignored the fact that Hap is a white ex-convict and Leonard is an African-American with dark skin having adventures in the Reagan-era South. The previous story was a caper involving Hap’s ex-wife Trudy (Christina Hendricks), who got them into trouble with nihilistic thugs. Television writers love to punctuate the villainy of such characters by having them sprinkle their vocabulary with epithets as casually as a smoker taps cigarette ash onto concrete. Leonard sustained his share of such abuse.

But the racial divide in the second season is distinct and purposeful, adding an anxious edge to Hap and Leonard’s interactions with the law — more specifically, Leonard’s troubles. And this new act makes “Hap and Leonard” into an allegory illustrating the senselessness of America’s racial divide, showing a community where black and white people live in close proximity while leading almost entirely separate lives.

“’Hap and Leonard’ is diversity to the tenth power. It doesn’t get more opposite ends of the spectrum than these two guys, and they love each other,” Williams told Salon earlier this year. “To me, that’s what makes America great, is that type of relationship. It’s cultural. When I say cultural, cultural is racial, but it’s also environmental. It’s generational. It’s a lot of different things, when you say culture.”

Fans of Lansdale’s novels will recognize the storyline for season 3 — which executive producer Jim Mickle calls “a third helping of mayhem” in a statement — from his book “The Two-Bear Mambo.”