Five sex offenders are challenging a ban that stops them from opening their doors to children on Halloween - with their lawyer comparing it to Nazi Germany's discrimination against Jews.
The ruling passed in Simi Valley, California, last month requires the offenders to post signs on their front doors saying: "No candy or treats at this residence."
It also bars them from displaying Halloween decorations or having exterior lighting on their property from 5pm to midnight on October 31.
Council members agreed that "traditional trick or treat activities associated with Halloween have the potential to provide significant opportunities for sex offenders to victimise minors".
The offenders' attorney filed a lawsuit in the US District Court in Los Angeles, alleging the ordinance violates the First and 14th Amendments because it "suppresses and unduly chills protected speech and expression".
Janice Bellucci, who heads an advocacy group called California Reform Our Sex Offender Laws, told The Los Angeles Times that she plans to ask the judge for an injunction to keep the city from enforcing its new law, particularly the requirement to have a sign in the front yard.
"To us, it's similar to branding," she told the newspaper. "We can think of what happened in Nazi Germany, where Jews had to appear in public wearing yellow stars."
City Attorney Marjorie Baxter told the Ventura County Star, which first reported on the lawsuit, that the city law was modeled on similar preemptive laws in other parts of Southern California.
"We thoroughly researched the ordinance and I don't feel the lawsuit has any merit, and we will defend it vigorously," she said.