The downfall of Texas Secretary of State David Whitley began in January with the blockbuster announcement that tens of thousands of noncitizens might have voted illegally in recent Texas elections.

President Trump immediately amped up this story by tweeting: “58,000 non-citizens voted in Texas, with 95,000 non-citizens registered to vote. These numbers are just the tip of the iceberg. All over the country, especially in California, voter fraud is rampant. Must be stopped. Strong voter ID!”

Secretary of State David Whitley: resigned after failed purge of voter rolls.

Suddenly, Whitley, a Republican appointee, was embroiled in a controversy over illegal immigration that brought into stark relief a seemingly unbridgeable partisan divide: between Republicans concerned about voter fraud and Democrats who accuse the GOP of trying to suppress minority turnout.

As evidence emerged that Whitley had overstated the problem, a firestorm erupted. By the time he resigned on May 28, Texas Democrats considered it a vindication, and even Republicans breathed a sigh of relief.

As a result, apparently no one is now investigating the extent of voting in Texas by noncitizens, who can qualify for a host of government services.

Although Texas pols seem intent on moving on, the episode raises fundamental questions about ballot integrity – specifically, whether the government has the technical and management skills to monitor and protect voter rolls and the political will to police them.

Austin, Texas: bilingual voting.

Here's what happened: On January 25, Whitley’s office sent out a press release saying it had identified some 98,000 noncitizens who might be registered to vote. Further, 58,000 of those identified had voted in Texas elections. The office arrived at those numbers by comparing lists of registered voters with those who had presented a green card or visa to get a drivers’ license or state-issued ID. It soon became obvious that there were problems with Whitley’s list. An official in the secretary of state’s office admitted that around 25,000 people had been included even though their citizenship was later established. The state quietly informed county officials of their error soon after the list was announced.

In the meantime, Whitley's office was sending out correspondence to voters on the list, letting them know that their status as legitimate voters was being questioned and their voter registrations stood to be cancelled if they did not respond with proof of citizenship. That outraged many of the people wrongly included. Voting rights groups were soon suing the state, and on February 27, U.S. District Court Judge Fred Biery in the Western District of Texas, issued a folksy decision quoting Robert Fulghum’s “All I Really Need to Know I Learned in Kindergarten” and chastising the state for creating “a solution looking for a problem.” Biery, a 72-year-old Bill Clinton appointee based in San Antonio, ordered the state to stop sending the letters and directed county clerks to stop removing voters from the rolls.

Taking voting seriously at the University of Central Florida.

After that, the state settled three lawsuits by agreeing to notify voters whose citizenship was questioned that they were no longer under scrutiny, and coughed up $450,000 in legal fees. With Whitley’s resignation, this effort to clean up the voter rolls was over, illustrating an exceptionally fraught process -- and not for the first time.

In 2012, Florida tried to match Division of Motor Vehicles data with voter rolls and initially claimed to have found 180,000 questionable registrations as a result. But that too ended with the discovery of bad data and lawsuits. The effort “was not only ruled against in the courts, but also in the court of public opinion, as citizens across the state were outraged to be identified as being noncitizens,” Daniel Smith, a University of Florida political science professor who studies voting rights, told RealClearInvestigations.

Smith points to one big problem. “Matching asynchronized records from data that are not updated and don’t have a unique linking identifier is going to lead to false positives,” he observes. He pointed to an academic paper by a University of Florida colleague and a Loyola Law School professor that looks at efforts to correlate voter registration data in light of “the birthday problem” – the statistical principle that in a room with a critical mass of people the odds that two share the same birthday is a surprising 50 percent or higher. It turns out that when combining two sets of data, the number of people sharing the same identifying markers is a lot higher than one might expect.

Out-of-date information is also a problem when people go several years between renewing a driver's license. Just because they were not citizens when they were issued IDs doesn’t mean they weren’t naturalized in the ensuing years. The federal government likely has more accurate data on the noncitizen population than states do, but historically the feds haven’t shared it with them. Attempts to do so would likely be met with more lawsuits, if the recent pitched opposition to the Trump administration’s attempt to add a citizenship question to the census is any guide.

Florida eventually winnowed its original list of 182,000 names down to 2,600, which was then turned over to local election supervisors. Local officials continued to find problems with the data, and ultimately only 85 people were removed from the rolls. Months later, the state gained access to some federal immigration databases and removed another 207 Floridians from voter rolls as a result.

Al Franken: narrow victor in disputed Senate race, and decisive vote on Obamacare.

By contrast, Texas’ recent effort to identify noncitizens was abandoned long before it could be winnowed down to a more accurate number. But given that many parts of the country – Florida in particular – have had recent elections decided by razor thin margins, the number of illegitimate voters doesn’t have to be very big to have a serious electoral impact.

Consider the U.S. Senate contest that Al Franken won in Minnesota in 2008 by a mere 312 votes. Ever since, observers have raised suspicions about felons illegally voting and other factors that would have erased the now-former senator’s victory. It was a pivotal outcome, ensuring the upper chamber’s deciding vote passing Obamacare.

Pennsylvania also has had problems maintaining accurate voter rolls. In 2017, Philadelphia City Commissioner Al Schmidt revealed that the city had been receiving "hundreds of letters from people cancelling their voter registration because they were not eligible.” It turned out that state’s motor-voter system – automatically registering voters getting driver’s licenses at the DMV -- had been "inadvertently" registering noncitizens to vote, according to the state.

Jeff Mateer, Texas assistant AG: “Quite frankly, I think we have a data problem.”

The state eventually hired an outside expert to come up with a list of Pennsylvania noncitizen residents who might be illegally registered to vote. There were as many as 100,000 illegal registrations, but the list was repeatedly winnowed down. And in January, after Pennsylvania Gov. Tom Wolf resisted attempts to release the information to the legislature, the state “admitted to finding names of 11,198 non-citizens registered to vote on the state’s rolls though the lawmakers suspect the number could still be higher,” according to the Associated Press.

Even in Texas, where there seems to be a strong desire to ensure fair elections, ballot-integrity work is foiled because resources and collective resolve are lacking. “We've done three noncitizen cases in the past year. ... They shouldn't have been voting and they were voting. We believe there are more of those,” Jeff Mateer, the first assistant attorney general of Texas, tells RealClearInvestigations. “Our problem is I've got, as of yesterday, two prosecutors and four investigators. That's not a lot of people to work on, not just these cases, but every election fraud case.”

Mateer adds that his office has a backlog of more than 80 referrals of potential election fraud. The Texas legislature recently approved more money to the AG’s office to deal with election fraud, but the system is overwhelmed.

Engaging the public on the issue in a way that doesn’t immediately devolve into partisan mudslinging about voter rights is also a big challenge. While mailing out thousands of letters questioning people’s citizenship might understandably be painted as voter intimidation, there are also political forces standing in the way of identifying and removing noncitizens from the voter rolls.

Stacey Abrams: Let the noncitizens vote.

Last year Texas Democrats indiscriminately mailed out voter registration forms in the Rio Grande Valley in south Texas, with the citizenship box already filled in. This is problematic because, when Congress in 1993 enacted the law commonly called the Motor Voter Act, “it envisioned a registrant making two separate affirmations of citizenship – both the checkbox as well as the signature attestation,” notes a letter from the Public Interest Legal Foundation that was sent out to local Texas District attorneys. “This enables prosecutors to easier establish intent and state of mind when noncitizens illegally register to vote.”

Meanwhile, left-wing activists are making no secret of their desire to give noncitizens the right to vote. Among them are former Democratic gubernatorial candidate Stacey Abrams, who accuses Republicans of voter suppression and refuses to accept her defeat in Georgia last year. As of last year San Francisco is allowing noncitizen voting in local elections, though public polling shows Americans are broadly opposed to the idea.

Ultimately, Mateer says, the lesson from the Texas debacle is not that there’s no cause to believe noncitizens aren’t voting – it’s that people need more information to determine what’s going on.

“Quite frankly,” he says, “I think we have a data problem.”