The diagnosis is in.

Medical testing showed that when actor Stacy Keach lost his way during the opening-night performance of “Pamplona” at the Goodman Theatre ┬álast week he was actually suffering a mild heart attack. The entire run of the one-man show about Ernest Hemingway, which was scheduled through June 25, was subsequently canceled.

The actor is now in the hospital recuperating and may be released Wednesday. Plans are for him to remain in Chicago for now (rather than return home to Los Angeles) so that he can continue his relationship with his doctors here.

“I visited Stacy in the hospital yesterday,” said Robert Falls, the Goodman’s artistic director and director of “Pamplona.”

“When I walked into the room he was sitting up and was studying the script,” ┬ásaid Falls, laughing. “And I turned to his daughter and said, ‘I hope he knows he’s not going on tonight.’ ”

According to Falls, “Stacy may actually have had the heart attack while on stage, but he had none of the classic symptoms of pain or tightness in his chest. It’s what is sometimes referred to as ‘a silent heart attack.’ ”

“Of course Stacy will need to rest. And we have already announced our next season. But I am looking for a spot next year when we might bring ‘Pamplona’ back.”