Way back in 1983, when I stood as the Labour candidate in the Bermondsey byelection, I proposed the idea of a single, comprehensive anti-discrimination law, to guarantee equal treatment and protection for everyone. At the time, this proposal was dismissed as "ultra left", as too radical and daring. Three decades later, however, it is close to reality.

The equality bill is continuing its passage through parliament this week and, baring sabotage in the House of Lords, will become law in 2010. One of its key aims is to remedy the uneven, variable patchwork of equality legislation. The separate laws on gender, race, disabilty, age, sexual orientation, gender identity and religion or belief, will be replaced by an all-inclusive legal framework. This will harmonise and standardise equality law, so that everyone has the same rights and protection.

Sadly, the proposed legislation does not quite live up to this laudable aim. Despite its name, the equality bill is less than equal. While guaranteeing full and direct protection against harassment to other vulnerable social groups, it denies this protection to lesbian, gay, bisexual and transgender (LGBT) people. This is not an omission or oversight. We are explicitly excluded from the anti-harassment clauses of the bill.

Also exempted is harassment on the grounds of religion or belief, in an apparent bid to appease religious bodies who want the freedom to victimise people of rival faiths or no faith. But that's another story.

The equality bill denies LGBT people protection in cases of homophobic harassment by school authorities, by the owners and managers of properties and by the providers of services. Similar harassment is specifically outlawed on the grounds of age, disability, race and sex. This omission gives a green light to homophobes. Under this section of law, they won't face sanctions for anti-gay victimisation.

LGBT organisations like School's Out are campaigning against homophobic and transphobic bullying and harassment in schools, some of which is perpetrated or tolerated by school staff, according to a Stonewall survey of LGBT pupils, The School Report (2007).

By excluding protection against harassment in schools on the grounds of gender reassignment and sexual orientation, this legislation is sending a signal to schools that the harassment of LGBT pupils need not be taken seriously.

Since the equality bill was intended to ensure comprehensive legal equality, all forms of harassment should be covered by its clauses. There should be no exemptions.

In its defence, the government claims that it consulted widely and that no one offered any evidence that harassment on the grounds of sexual orientation was a serious problem that needed to be included in the bill. This is not true. The government initially consulted only the gay lobby group Stonewall. This is one LGBT group among many and it does not deal with individuals suffering homophobic harassment. Until recently, government ministers failed to consult the two LGBT organisations that assist most victims of harassment: the homophobic hate crime group, Galop, and OutRage! We have plenty of casework evidence to show that anti-gay harassment is a significant problem and that it should be specifically outlawed by the equality bill.

The deputy minister for women and equalities, Maria Eagle MP, has also justified the exclusion of LGBT people from the anti-harassment clauses with the argument that we are protected under the Equality Bill's "discrimination provisions." She wrote to me: "If a teacher ignores the bullying of a LGBT child despite tackling other bullying, this would be unlawful discrimination." In fact, this is only indirect protection against homophobic harassment. Moreover, it is dependent on the LGBT child not only being able to prove that he or she was bullied and that no action was taken, but also that others were bullied for other reasons and that remedial action was pursued by the school authorities. In other words, under the equality bill, LGBT victims of homophobic harassment are to required to prove two things to get justice. In contrast, victims of racial or gender harassment have to prove only that the harassment took place. They get direct protection.

The government also claims that we are making a fuss over nothing because LGBT people are already protected under general anti-harassment legislation. We don't need additional protection in the equality bill, according to ministers. However, women, black, elderly and disabled people are also protected under general anti-harassment laws, yet they are included in the bill, while LGBTs are not.

Why the double standards? What happened to the level playing field and equal treatment that was promised when this bill was first tabled?

The government seems to be saying that a gay person who is homophobically harassed can secure protection under general anti-harassment law, but if an ethnic minority person is racially harassed they should be protected under both the general laws against harassment and, in addition, under the equality bill.

To put it bluntly: Labour is creating a two tier legal system and denying equal protection to lesbian, gay, bisexual and transgender people.

Members of the parliamentary Joint Committee on Human Rights, such as Evan Harris MP, have similar concerns. They support extending the anti-harassment protection of the equality bill to cover sexual orientation and gender identity.

Unfortunately, the government has thwarted attempts to amend the legislation by allowing very little parliamentary time for debate; thereby ensuring that the concerns of the LGBT community are not remedied.

Other legitimate concerns have also been given short-shrift. These include doubts expressed by the British Humanist Association and the Accord Coalition about the wisdom and morality of, in certain circumstances, exempting religious bodies from the requirement to not discriminate. There should have been parliamentary time made available to discuss these issues too.

The way the government has handled the equality bill is typical of its frequent arrogance and high-handedness. A commendable piece of legislation has been besmirched by the failure to fully protect against homophobic harassment. Moreover, the truncation of parliamentary scrutiny and debate has not only been bad for the LGBT community; it is bad for democracy itself.