A Pennsylvania House candidate who lost the Republican primary has been presented with the unexpected possibility that he might compete in the general election — as a Democrat.

An early tally of write-in votes on Tuesday put tea party-backed conservative Art Halvorson slightly ahead of Democrat Adam Sedlock in the Democratic primary, potentially giving Halvorson the option of accepting the nomination from the rival party, the Tribune-Democrat in Johnstown reported.

Halvorson, a retired Coast Guard captain and businessman, would then face a general election in the 9th Congressional District against incumbent Rep. Bill Shuster, who beat him in the April Republican primary by a little more than 1 percentage point.

But first, election officials must finish counting the ballots in a race that was so close that the candidates had to petition some precincts to accept every possible misspelling of their names.

Halvorson said he did not pursue votes from the other side of the aisle, but, while he had not made a decision about the Democratic nomination, he appreciated the support, the paper reported.