In more recent years, the LeBarón community had established a sort of truce with the cartels, Ms. Wariner said. They had an understanding, she said, that the community would not go after the traffickers if the traffickers left the community members alone. She said the killings were a surprise because there did not seem to be a cause for such an attack.

“Things seemed to be getting more peaceful,” Ms Wariner said.

But one woman who asked not to be named out of fear for her safety said families traveling between the LeBarón and La Mora communities had been getting stopped lately by cartel members who asked where they were going and what they were doing.

They have generally been respectful, and did not seem to care about ordinary travel, the woman said.

But David Langford, who grew up in La Mora, said cartel members recently had been warning people to “stay off” the road between the La Mora and LeBarón communities at night.

“We did,” Mr. Langford said. It was a big change from the “peaceful” place that northern Mexico was when he grew up, he added.

“What just happened has never happened in this valley — ever,” he said. “We’ve been traveling that road for 50 years.”

Simon Romero reported from Queen Creek, Elizabeth Dias from Washington, Julie Turkewitz from Denver, and Mike Baker from Seattle. Susan C. Beachy contributed research.