Credit: Frazer Harrison/WireImage

Following the casting of Idris Elba in Molly’s Game opposite Jessica Chastain, Aaron Sorkin’s directorial debut is close to getting picked up by STX Entertainment, EW has learned.

STX is in final negotiations to acquire the film, marking the first big deal coming out of this year’s Cannes Film Festival. Deadline was the first to report the news and states the sale is around $9 million.

Sorkin wrote the script based on Molly Bloom’s memoir of the same name about the world-class Olympic skier who ran a high-stakes poke game for a decade until she was arrested by FBI agents. Chastain plays Molly, while Elba plays her criminal defense lawyer, who learns there’s more to his client than what’s in the tabloids.

The film will mark Sorkin’s first time up to bat in the director’s chair, in addition to a reunion with Mark Gordon, who helped produce Steve Jobs.

“The casting of Jessica and Idris in the two lead roles is any filmmaker’s dream come true,” Sorkin said earlier in a statement. “They’re two of the greatest actors of their generation, paired for the first time, and their chemistry will be electric.”