California has banned state court judges from belonging to the Boy Scouts. The move extends an earlier ban on judges belonging to groups that discriminate on the basis of sexual orientation, but had an exemption for youth groups. Judges have one year to sever their ties with the Boy Scouts.

Judges are already banned from joining lots of groups that other people can belong to. For example, they can't be members of country clubs that don't admit Jews or women.

But banning them from the Boy Scouts, a group long associated with old-fashioned wholesomeness despite prohibiting gay troop leaders, seems to many people a step too far.

At a meeting in Oakland, boy scouts sing and discuss volunteer projects. High school student Matan Bostick gives a speech after being inducted to the Eagle Scouts, the group's highest rank.

"The Boy Scouts made us men," Bostick says. "They made us tough and it gave us the ability to laugh in the face of our own discomfort."

But it's the Boy Scout's very discomfort with homosexuality that has led the California Supreme Court to ban the state's 2,200 judges from participating in the group.

The Boy Scouts declined to comment for this story. But many people, like San Diego Judge Julia Kelety, are upset.

"The issue is whether individual judges can choose in their private lives to be involved in an organization that has tremendous qualities and provides tremendous support for young people," she says.

Kelety has deep ties to the group. Her brothers were scouts, her dad was a scout leader and she's chairwoman of her two sons' troop.

"And I don't think that a person appearing in my court would think that I'm biased or unfair simply because I help my sons out in their Boy Scout troop," she says.

Robert Glusman is former president of the California Judges Association, which supports the ban.

"Would a judge be able to join an organization where black men could not be part of the organization? I don't think that would be as close a question," Glusman says. "Here we're dealing with gay men or LGBT. So we put it in a slightly different framework, but there is something that rankles many of the judges about that."

Of course, judges are free to belong to whatever religious organizations they want. And lots of religions do discriminate in some fashion, like the Catholic Church prohibiting female clergy.

Harvard Law Professor Noah Feldman says the current state of the law allows judges to belong to religious groups that discriminate but not secular organizations that discriminate.

"So if the particular judicial code bans belonging to organizations that discriminate on the basis of sexual orientation, then it would make sense that the Boy Scouts would be included," he says.

But Feldman predicts the U.S. Supreme Court will one day take up the question of judges' free association rights. And if that happens, Feldman thinks the court will say judges can participate in the Boy Scouts, regardless of the group's anti-gay policies.

"You have a free exercise right to pray where you wish. And you have a free association right to belong to whatever club you wish to belong to," he says. "And I don't actually think the distinction between the two is constitutionally justified."

The distinction that divides judges' personal lives and professional lives has always tracked a fine line. In recent years, it is in perhaps no greater area than gay rights that these tensions have been laid so bare.

Copyright 2015 NPR. To see more, visit http://www.npr.org/.