Annoying a police officer may soon be punishable by up to a year in jail in an upstate New York county hoping to avoid incidents like the dousing of police officers with water.

Under a proposal that was approved by the Monroe County Legislature, someone who annoys, alarms or threatens a police officer or other first responder could be arrested and sentenced to a year in jail or forced to pay a $5,000 fine.

The legislature approved the bill by a 17-10 vote on Tuesday. The county executive will now hold a public hearing and decide whether to pass it into law.

The bill sparked outrage among groups such as the New York Civil Liberties Union.

“Members of the community have every right to challenge police officers, particularly those that engage in unnecessary behavior,” Iman Abid of the NYCLU said in a statement.

“At a time when more accountability of police departments is needed, this law takes us incredibly backward,” she added.

In a news release about the proposed law, the legislature mentioned the water-bucket dousing of NYPD officers this summer as evidence the law is needed.

But Delores Jones-Brown, a professor at John Jay College, said the proposed legislation was constitutionally vague that could infringe on someone’s constitutional rights.

With Post Wires