NEW YORK — For the Mets, eight innings of frustration were about to melt away. Hosted by Shota Imanaga and the Cubs on Wednesday night, the Mets got an opener when they scored two men in the ninth with one out. Jeff McNeil followed with a fly ball about two-thirds down the left-field line — maybe enough to score Pete Alonso, maybe not.

With the game on the line, Alonso ran with his head down. As he did, Cubs catcher Miguel Amaya stood up to receive a throw, one-footed half-way home. Finally, Amaya turned left to catch third baseman Nick Madrigal’s pass, covering the extra plate in the process. Alonso slid in first and landed between Amaya’s legs.

Everything came together at once. Home umpire Charlie Ramos called Alonso off, officially ending the game with a 1-0 loss. And so the chaos began.

As players from both sides watched from their stands, Major League Baseball’s replay team examined two aspects of the play: Was Amaya illegally blocking home plate? And if not, does Alonso’s hand tap home before Amaya tags in?

After four minutes of deliberation, replay official Derek Thomas made his final decisions: No, and no hearing. Alonso was ruled out and the Cubs victory left many in the home clubhouse at Citi Field in disbelief.

“I think they got the wrong call,” Mets manager Carlos Mendoza said.

Mendoza’s primary contention was that MLB rules prohibit catchers from covering home plate without a baseball. The so-called “Buster Posey Rule,” designed to reduce collisions, states, “The catcher is not allowed to block the path to the plate unless he has caught the ball, even if he blocks the path of the runner.” A legal attempt to receive a throw is not considered a foul. The law adds that if the runner has violated the runner, the runner can be safely convicted.

Mendoza said of MLB, “In spring training, they send memos of what’s legal and what’s illegal.” “In that email, the memo we got, it’s clear that catchers are not allowed to put their feet in front of the plate, on top of the plate. You can’t walk without a baseball. It was very clear. [Amaya] He had his left foot over the plate without the baseball.

Although Amaya didn’t go home, half of his legs were on it.

“I was 100 percent sure of myself. [that I wasn’t blocking the plate]” Amaya said. “I gave him the lane and then they [had] The review is exactly what I thought it would be. “

Asked if he understood the rule, Mets catcher Omar Narvaez replied, “I don’t think so anymore.”

“Everybody thought we got the call,” he added.

The ruling abruptly ended what had been mostly a pitcher’s duel for eight innings. Imanaga limited the Mets to three hits over seven scoreless innings, while Jose Bhutto nearly kept the streak going with six innings of one-run ball. The Mets threatened in the eighth but did not score. Finally, in the ninth, Cubs closer Hector Neris found life when he hit Alonso with a pitch and JD Martinez followed with a leadoff double.

With one out and first base empty, the Cubs elected to march to McNeil, who hit an opposite-field fly 272 feet down the left field line. Alonso returned home. Ramos called him. Mendoza burst onto the field to compete.

Alonso was shown a video replay on the scoreboard in midfield as both teams awaited the verdict. Helmet still in hand, he held out both arms wide to show he believed he was safe.

“At first it happened, I thought I slipped my hand in there,” Alonso said. “But the phone told me I was out, so I was.”

After the game, several of Alonso’s team-mates believed he was still safe. Amaya argued that he had done nothing wrong. Mendoza said he looks forward to hearing more from MLB on the issue, though he and Alonso acknowledge that the argument is overdue.

“I went as fast as I could,” Alonso said. “I made the best slide I could. The referee said I was out, so I was out.”