The state of Texas takes voting illegally serious – serious enough to send a woman to prison for 8 years.

The woman, Rosa Maria Ortega, is a green card holder who was born in Mexico, and her attorney claimed she “mistakenly” voted — for more than a decade.

Attorney Clark Birdsall told The Washington Post that his client was faced with only two options on her voter application — to mark herself as a ‘citizen’ or a ‘noncitizen’ — and didn’t know better.

“She doesn’t know. She’s got this [green] card that says ‘resident’ on it, so she doesn’t mark that she’s not a citizen,” Birdsall said. “She had no ulterior motive beyond what she thought, mistakenly, was her civic duty.”

Texas Attorney General Ken Paxton announced on Tuesday the 2nd Court of Appeals has upheld a 2017 conviction against Ortega, who was then sentenced to eight years in prison.

Paxton said in a statement Tuesday that the conviction was a necessary crackdown on illegal voting — ironically, Ortega voted for the Republican attorney general.

“This case underscores the importance that Texans place on the institution of voting, and the hallowed principle that every citizen’s vote must count,” Paxton said. “We will hold those accountable who falsely claim eligibility and purposely subvert the election process in Texas.”

He also noted that Ortega was offered the minimum punishment for the offense – two years community supervision, no prison, and no special conditions.

She instead chose a jury trial, which makes one wonder what role her lawyer played in what proved to be a very poor decision.

As for her claim that it was an innocent mistake, Ortega got it right when obtaining a driver’s license, informing authorities that she was a resident alien.