The tech industry isn't big on dress codes, employee handbooks, or rules. The Silicon Valley management philosophy is simple: Hire talented coders, give them tools to do their jobs, and get out of their way. The best coders should be rewarded, and those who just can't hack it should be let go.

The problem is that, all too often, workplace problems boil down to more than just code. Yesterday widely respected programmer Susan J. Fowler revealed in a blog post that she quit her job at the transportation company Uber last year after facing sexual harassment, discrimination, and, perhaps most worryingly, a corporate culture that let all that harassment and discrimination slide.

One of the most striking things about the allegations is how unsurprising they are. Uber has always had a cavalier attitude about rules and regulations, so it's easy to imagine that attitude extending to sexual harassment and employment laws in general. But the issue goes far beyond Uber. Stories like Fowler's are common in the tech industry, which has never quite gotten a handle on how to hold employees accountable for anything other than "performance."

Fowler, a frequent speaker at conferences and author of the book Production-Ready Microservices, claims that shortly after she joined Uber, her manager propositioned her. She reported him to Human Resources, she writes, but was told that because it was the manager's first offense, no action would be taken. She had the choice between staying on his team, where she was allegedly told that she might receive a poor performance review in retaliation, or transfer to another team. She chose to transfer.

Fowler writes that she later found out it was not this manager's first offense at all, and that although he eventually left the company, he wasn't disciplined—even after more women had reported him for sexual harassment.

That was just the beginning. Fowler describes a dysfunctional, Game of Thrones-esque company culture, with management admitting that she was given a bad performance review for non-work related reasons, and, ultimately, a manager threatening to fire her if she continued reporting discrimination to the HR department. A common refrain, each time she complained to HR about a harasser, was that the person in question was a "high performer."

Uber is bringing in former attorney general Eric Holder and his colleague at the law firm Covington & Burling, Tammy Albarrán, to investigate the issues Fowler raised as well as diversity issues in general, according to a memo that CEO Travis Kalanick sent to employees today. Media mogul and Uber board member Arianna Huffington, the company's new chief human resources officer Liane Hornsey, and its general counsel Angela Padilla will join them in the investigation. "I believe in creating a workplace where a deep sense of justice underpins everything we do," Kalanick wrote in the memo.

Uber has a troubled history on gender relations. In 2014, Kalanick told GQ that he called the company "Boob-er" because it has made him more attractive to women. That same year, the company ran an ad in France promising to pair customers with "hot chick" drivers. When journalist Sarah Lacy suggested that this sort of sexism was a problem, Uber senior vice president Emil Michael suggested digging up dirt on her to ruin her reputation, according to BuzzFeed. Kalanick tweeted that Michael's comments didn't represent Uber's views, but Michael kept his job.

The company isn't the only tech darling to face these kind of problems, though. Fowler's story retraces what has become a familiar sequence of events: A female employee complains about sexual harassment and/or discrimination to HR. The company takes no action. The employee takes to the internet to complain. Media attention follows. The company promises to investigate. Sometimes someone resigns in scandal. But the industry itself stays the same.

In 2014, a former employee of the code hosting and collaboration site GitHub claimed one of the company's programmers sexually harassed her, and that one of the founder's wives had also repeatedly harassed her—despite multiple reports to the company's HR department. After a flurry of media coverage, GitHub conducted an investigation into the matter and concluded that while no laws had been broken, employees had made "mistakes and errors of judgment." Then-CEO Tom Preston-Werner ended up resigning as a result.

In 2015, a former Google employee accused executives of sexual harassment. She claims she reported the harassment to HR, that neither of the harassers were disciplined, and that she was fired for pouring a drink on one of them.

Last year a former Squarespace employee wrote that a manager told her "you’re so black, you blend into the chair." Once again, the employee claimed to have reported the incident to HR, but that nothing came of it.

The implication is that as long as a programmer is writing good code, a manager is shipping products, or an executive is hitting sales goals, then nothing else matters.

The problem isn't limited to startups. In 2010, a former contractor at HP accused CEO Mark Hurd of sexual harassment. The company concluded that Hurd hadn't violated sexual harassment policy, but had violated his standards contract. Hurd resigned, but Oracle promptly hired him as president. Now he's the co-CEO of Oracle.

This pattern reveals a huge accountability problem. Many tech companies' HR departments seem to have either no will or no ability to discipline employees. The racism and sexism pervasive in the tech industry leads to disbelief of victims' claims, and their contributions to their companies are often not valued. The consequences for accused harassers are often minor. Even those who are forced out, like Hurd, may find themselves in comparable jobs at other companies. The implication is that as long as the programmer is writing good code, the manager is shipping products, or the executive is hitting sales goals, then nothing else matters.

But this libertarian approach to management can backfire. Companies not only have a moral imperative to protect their employees, but a business imperative too. In 2008, a study by a group of psychologists found that sexual harassment reduces productivity and job satisfaction and increases turnover, stress, and health care costs. A report from McKinsey, meanwhile, concluded that diverse teams are more productive.

It's time for Silicon Valley to realize that being a good employee means more than just being good at your job—and that being good to employees means more than just stock options, free snacks, and a foosball table.

UPDATE 7:15pm ET 02/20/17 This story was updated to include details of a memo from Uber CEO Travis Kalanick.