A few months ago, a Google engineer named James Damore wrote an incendiary internal memo on a 12-hour flight to China. He had just attended a “diversity programme” run by his employer, which had clearly annoyed or disturbed him. “I heard things that I definitely disagreed with,” he later told an interviewer. He said there was a lot of shaming at the programme. “They said ‘No you can’t say that, that’s sexist… You can’t do this…’ There’s just so much hypocrisy in a lot of the things that they’re saying.”

Damore’s 10-page memo – entitled “Google’s Ideological Echo Chamber: how bias clouds our thinking about diversity and inclusion” – went viral within Google, and eventually news of it reached the outside world. When it did, it provoked a predictable firestorm. In the memo, Damore accused Google of silencing conservative opinions and creating a climate in which “some ideas are too sacred to be honestly discussed”.

He also argued that biological differences play a role in the shortage of women in tech and that the focus on race and gender bias within Google has led to the company ignoring a diversity of ideas, particularly moral ones. “At Google,” he wrote, “we talk so much about unconscious bias as it applies to race and gender, but we rarely discuss our moral biases.” The leftwing bias of Google, he claimed, leads it to miss what he believes are “personality differences between men and women that cause the gender gap in tech companies”. And so on. As a compendium of provocations for a wide range of audiences, Damore’s memo was a masterpiece.

The company’s response to the mini-crisis was, to put it charitably, inept. Exhibit A is the blog post from the company’s CEO, Sundar Pichai, saying that while “much of what was in that memo is fair to debate, regardless of whether a vast majority of Googlers disagree with it”, he was nevertheless firing Damore for violating the company’s code of conduct. As an own goal this would be hard to beat, and it immediately elevated the memo’s author to rock-star status with the “alt-right” and opponents of “political correctness” everywhere.

IQs may be higher in the valley, but venture capitalists look awfully like nerds with Learjets behaving like frat boys

For this columnist, though, the most annoying thing about the Damore controversy is the way it diverts attention from an even bigger scandal than gender imbalance in software engineering. This is the old-style male chauvinism and manipulative sexism that prevails at the more glamorous end of Silicon Valley – particularly in the venture capital firms and the swaggering CEOs of successful startups. One thinks, for example, of Travis Kalanick, the former CEO of Uber, impaled on his priapic sword after ex-employee Susan Fowler blew the whistle on the poisonous corporate culture that he fostered. But he’s just one of many.

The glossiest bit of Silicon Valley is not Mountain View or Cupertino, but Sand Hill Road in Menlo Park. This is where the top venture capital companies hang out. The most venerable is Kleiner Perkins Caufield and Byers, a company whose partners have invested in many of the biggest tech success stories of our time.

The managing partner in Kleiner Perkins is John Doerr, a legendary investor whose current net worth is estimated at $6bn (£4.6bn). A few years ago he advertised for a chief of staff to enable him to better “leverage” his time (which he values at $200,000 per hour). Ellen Pao, a phenomenal woman with degrees from Princeton and Harvard in engineering, law and business, who had also worked in consultancy and startups and spoke Mandarin, got the job and became a junior partner in the firm.

Pao never made it to senior partner, even though she had led on some significant investments. She was also subjected to sexual harassment and eventually broke off a relationship with a junior male colleague. Her periodic performance reviews became negative and eventually she sued the firm for gender discrimination alleging workplace retaliation by her rejected suitor. The case was a minor sensation in the valley because it lifted the lid on what went on in one of its most hallowed firms. But in the end the jury sided with the firm.

Now, however, Pao has decided to tell her story. Reset: My Fight for Inclusion and Radical Change comes out next month. For anyone who cherishes the illusion that the tech industry is somehow superior to, say, investment banking, Pao’s book will come as a shock. IQs may be higher in the valley than they are on Wall Street, but otherwise the venture capital business looks awfully like nerds with Learjets behaving like frat boys on steroids. And – incidentally – it also helps to explain why women find it so difficult to get funding for their startups. Because they do. They say a fish rots from the head down. Same goes for Silicon Valley.