San Francisco: The Worst-Run Big City in the U.S. - <AUTHOR> http://www.sfweekly.com/2009-12-16/news/the-worst-run-big-city-in-the-u-s/1 <comment><USER3> The biggest problem in San Francisco is not the city government nor the government workers but its the voters.

SF is a city of really well meaning people who will sign any petition when they leave Safeways and vote yes to every single idiotic ballot issue.

What this means is that every single interest group gets people to vote them funding.

Of course the people voted in are all of the same political flavor so rather than having devils advocates amongst the commissioners you get each of them pushing for spending on their particular special interest groups.

Unless the voters start voting no to these idiots and ballot measures I don't see anything changing in SF in the foreseeable future.

<comment><USER4> San Franciscans have the same problem Mike Huckabee has: they're naive. They want to believe that anyone espousing the same moral values as them must be honest and trustworthy. They want to believe that acting with good intentions produces good outcomes.

This thinking is worthy of an eight-year-old. _This is why we love children._ The innocence, the wonder. _This is why growing up is painful._ You do something with good intentions and end up breaking something or hurting someone. You meet someone who seems nice and believes all the same things you do, and they lie to you and steal from you.

Nobody connected with any deep religious or artistic tradition should need to be so naive. Believing in evil is compatible with mercy. Believing in betrayal is compatible with trust. Believing in waste, inefficiency, and rent-seeking is compatible with a determination to apply the resources of government to improve people's lives.

<comment><USER5> I dunno, i think this is too reductive, putting all the blame on a unique aspect of San Franciscan character. It sounds like the ballot system there allows for this kind of chaos, and so of course it ensues. It would happen anywhere. It might not always have the same generally lefty bent that San Fran's does, but otherwise I think its bad governance structure, not bad people.

<comment><USER3> While governance and a flawed ballot system are definitely a big issue, the real reason it has been exploited the way it is is that there is no real opposition in SF. And that I'm afraid is because of this particular aspect of San Francisco group think.

</comment></comment></comment></comment><comment><USER6> Don't worry - San Francisco has a solution to all their problems, DC's _limitless pot of stimulus gold:_

Standing among racks of freshly dry-cleaned clothes in the Bayview, Mayor Gavin Newsom today touted San Francisco's early grab at federal stimulus dollars which have put 1,200 unemployed city residents to work - <USER2> sprucing up dirty clothes at Laundry Locker.

But there are, um, a couple of wrinkles that Newsom wants to iron out. The program, part of the American Reinvestment and Recovery Act, provides $5 billion nationally to fully subsidize the hiring of unemployed workers. But they must have at least one child under age 18, leaving out many jobless and childless San Franciscans. And the money is due to run out in September 2010, meaning the newly hired could soon be back in the unemployment line.

Newsom said he's headed to Washington, D.C. next week to lobby House Speaker Nancy Pelosi for an extension of the money and to include people without children. He said he wants to see 2,500 or even more San Franciscans hired, and that the majority of California's $1.8 billion pot is still sitting waiting to be grabbed by cities since so few are participating.

"This is limitless. It's just a matter of who draws down the money fastest," Newsom said. "We discovered a pot of gold in the stimulus money."

[http://www.sfgate.com/cgi- bin/blogs/cityinsider/detail?entry...](http://www.sfgate.com/cgi- bin/blogs/cityinsider/detail?entry_id=53313&tsp=1)

</comment><comment><USER7> A few comments:

\- SF's massive spending on the needy would seem to attract more needy people, so the point of comparison to the rest of the bay area could be misleading. SF also has a more consistent climate than the rest of the bay area, useful if you're homeless and sleeping on the street.

\- Whole sections of the city are overrun with homeless people (tenderloin, golden gate park near Stanyan) such that passers by may be attacked, etc. I am aware of 3 people who have been attacked by homeless people.

\- The MUNI system is decent, but there is little enforcement of fare violations. Not sure if this is really a problem.

\- The mom and pop restaurants in SF are the best I've tried in any city, including New York.

\- The level of tolerance in SF is fairly remarkable. You can dress however you want, men can wear nail polish, etc., and nobody bats and eyelash. One should not underestimate the importance of this sort of tolerance.

\- I agree that rent control is a big problem. It's just bad policy and unfortunately it plagues lots of big cities.

\- I don't know why there is a housing project in Hayes Valley. It's hard not to feel poor in SF if you earn over $100K Per year, and so one can imagine how it must feel to actually be poor.

<comment><USER8> _You can dress however you want, men can wear nail polish, etc., and nobody bats and eyelash. One should not underestimate the importance of this sort of tolerance._

Ah, but try wearing a "Bush/Cheney 04" t-shirt and see what kind of reaction you get. One should not underestimate the importance of this kind of intolerance. Who cares about wearing nailpolish when you'll be ostracized for having political opinions which anywhere else would be perfectly mainstream?

<comment><USER7> You are absolutely right about that.

I think the homeless and gay populations reveal that SF has an above average amount of tolerance for differences (in general, but with heated disapproval by vocal minorities) but that certainly doesn't mean that if you choose a SF resident out of a hat and show him a GWB t-shirt, that he won't reveal himself to have utterly un-nuanced (even boneheaded) views on topics such as the differences between the parties, relevant details of the Bush administration's policies, even things that he ostensibly supports like gay rights, clean environment, and nationalized healthcare.

I think the bottom line is that there are some very dumb people who thoughtlessly parrot what they perceive as "enlightened" views, who couldn't explain why if asked... essentially "dittoheads" of the left.

Note: I'm a libertarian (small L) so I find fault with a lot of ways that people reason (or more often bleat) about political issues.

</comment></comment></comment><comment><USER9> Having made an attempt to live there, and having then left, here is my summary: San Francisco is a city populated entirely by 2 kinds of people: adult children, and public servants/long-term welfare cases.

that's about it. people who are, or become grownups move away in disgust that such a wildly beautiful and rich place is such a sewer at the same time. sad really.

<comment><USER10> I'd agree if you didn't use the word "entirely." I grew up in the south/west half of San Francisco, which is still, remarkably enough, populated largely by families who struggle, with eyes wide open, in the same way that most middle- class families do (their incomes would appear to be high, but the cost of living means that they're not all that different from someone making a third of that salary in a less expensive city).

I have two young children here, and I've started to watch the beginning of the exodus (there are many families with small children in SF, even the trendy parts... they generally start to leave when the first, and especially the second, hit school age. Space, schools, all that stuff).

Many of the people who stay in SF have extended family here. There are also the people who love it, but my wife and I have a new theory - the people who express unqualified love for SF will probably leave. Its the ones who mix it a grim recognition that, for whatever reason, they'll never get to check out of this place - those are the ones who will still be here in 30 years. Hell, my parents have been complaining about it since I was born.

You know, welcome to the hotel san francisco, if not hotel california.

<comment><USER11> Ah, I see why SF attracts so many homosexuals, cost of living is much lower when you don't have to provide for children. So, homosexuals both get a nice living area, and all the heterosexuals who form families and might look down on their choices are filtered out. Best of both worlds for them.

<comment><USER12> That's a weird way of looking at it.

1) The cost of living is still outrageous even for couples without children, and the gayest areas are among the most expensive. SF attracts homosexuals due to the culture and history.

2) What does raising a family have to do with "looking down" on anyone? All the parents I know in SF raise their kids to be as gay-friendly as they are.

Also: you are aware that some _kids_ are gay, right? Most of them figure it out very early, it's only homophobia that makes them suppress it until university.

You're right that there is a political side effect of de-prioritizing children, since most gay or lesbian couples are childless. But that's also fueled by the high concentration of childless professionals in SF. It is a snowball effect that will accelerate until the city's unlivable for people with children.

I just don't think it's a conspiracy. One might argue that the real conspiracy is gentrification, where family-friendly neighborhoods are swept away to provide yuppie housing.

<comment><USER11> I don't think it's a conspiracy, just the result of a couple variables.

At any rate, #1 supports my point. Since they are the most expensive areas, they'll be even less likely to host families. On the other hand, if gay people tended to live in low income areas, that would invalidate my hypothesis.

#2 doesn't really cause problems for my argument either. I suspect that if anyone is going to be gay-unfriendly, it is going to be heterosexual couples who have children. Especially if they have a large family they likely belong to a religious tradition that considers homosexual sex to be immoral. So, if most people, invariant over whether they have families or not, make an effort to be gay-friendly, I still suspect a random sample of families vs singles will turn up more gay-unfriendlies.

Finally, childlessness may also cause people to choose homosexuality. Most people want sexual intimacy, but they don't want the risk of having children. They can use a bunch of unreliable methods to avoid producing children in a heterosexual relationship, or they can take the easy way out and choose a homosexual relationship.

</comment></comment></comment></comment></comment><comment><USER13> Some good points, but a whole lot of outright bullshit as well.

 _San Francisco can't point to progress on many of the social issues it spends liberally to tackle_

Oh really? Maybe you should take a look at the healthy San Francisco program, which basically arranges medical insurance for the indigent. That works. I like to grumble about Muni, the public transit system, but the fact is that it covers the entire city, is (mostly) available around the clock, and every vehicle is GPS tracked so you can find out when the next one is coming. I've called in problems on a bus by phone before and had an inspector board the bus a few stops later to resolve the issue.

Although many of the criticisms in the article are individually valid, many of them are divorced from context, eg not considering the facts of state politics. There are a bunch of things that need reforming in San Francisco, but this article is hit piece rather than serious journalism.

There are two free weekly newspapers in San Francisco. For years the Bay Guardian has been the standard bearer for grumpy hippy activism (and by 'grumpy' I mean an interest in basic fiscal rectitude). The SF Weekly, by contrast, has done much better out of promoting entertainment and lifestyle with some human-interest stories sprinkled in as news; indeed, for several years they've had a policies of not even offering endorsements at election time or putting any resources into election coverage. Now both papers have seen a calamitous drop in advertising, both classified and display, and have shrunk from tabloid to magazine size. And the SF weekly is desperately churning out what it regards as hard-hitting journalism in a bid to stay relevant, after years of coverage that amounted to little more than 'LOL politics'.

<comment><USER14> > Maybe you should take a look at the healthy San Francisco program, which > basically arranges medical insurance for the indigent.

Maybe that increases the number of indigent? Why, in one of the richest, most beautiful cities in the wealthiest country in the history of the world, are there large numbers of feral humans roaming around? Why are entire neighborhoods off-limits to law-abiding citizens?

<comment><USER15> Feral humans are people too.

Can you explain to me why only rich people ought to live in cities?

<comment><USER14> I'm definitely not talking about poor people. I'm talking about people who are literally incapable of living in a civilized society. People such as:

[http://www.sfgate.com/cgi- bin/article.cgi?f=/c/a/2009/12/02/...](http://www.sfgate.com/cgi- bin/article.cgi?f=/c/a/2009/12/02/BAPF1ATVOU.DTL) (multiple random stabbings on Muni and the streets)

<http://en.wikipedia.org/wiki/Edwin_Ramos> (Triple drive-by gang murder against people he erroneously thought were in a rival gang)

[http://www.sfgate.com/cgi- bin/article.cgi?f=/c/a/2009/11/24/...](http://www.sfgate.com/cgi- bin/article.cgi?f=/c/a/2009/11/24/BA681APQCR.DTL&feed=rss.bayarea) (Murdered a pizzeria employee apparently because she didn't like his beard)

That guy I saw defecating on Haight Street (ok, maybe that one was my fault for going to the Haight).

BTW congrats on item 10^6 :-)

<comment><USER16> I could cherry pick some senseless violence stories from any large American city. They don't prove anything.

While I do think San Francisco is poorly managed, it's naive to think that its homeless problem is caused solely by bad governance. It's a combination of a lot of different things: the hippies that turned into deranged homeless people, the strong lure of California for those down on their luck, the strong drug culture, the very consistent temperatures, the size of Golden Gate Park, etc.

<comment><USER17> ...Not to mention that Giulani bought bus and train tickets for huge numbers of homeless in NYC and sent them out West....

</comment></comment></comment></comment></comment></comment><comment><USER18> _"It's time to face facts: San Francisco is spectacularly mismanaged and arguably the worst-run big city in America. This year's city budget is an astonishing $6.6 billion — more than twice the budget for the entire state of Idaho — for roughly 800,000 residents."_

That comparison is so disingenuous. They're comparing a _city_ with one of the highest costs of living in the country to the second poorest Western _state_? The cost of living in SF is about double that of Idaho. The median value of a home in SF is $656,700, while in Idaho it's $138,190. So why the "astonishment" at SF's budget being _only_ twice that of Idaho?

Then there's the population issue. The whole of Idaho has 1.5 million people, while SF alone has 0.8 million. That's a huge concentration of people in one city. Compare SF to Boise, the largest city in Idaho: SF has 4 times the population. That kind of concentration of people brings lots of problems just by itself.

I'm not saying SF doesn't have problems. It clearly does. But this particular comparison isn't exactly the fairest they could have come up with. How about a direct comparison between the budget of SF and, say, NYC?

<comment><USER19> It is a poor comparison, because the services provided by the state of Idaho and the city of San Francisco are so different. The author should have compared the sum of budgets of all cities in Idaho, or better yet found cities that are individually similar to San Francisco in ways other than spending (such as San Jose or Jersey City).

I think you're wrong about population and density though. I'd expect that the huge concentration of people would lower per-capita infrastructure costs and enable other economies of scale. Comparing San Francisco to New York City, we find that NYC, with 8.3 million residents [1] in 305 sq. mi [2] has budgeted $43.4 billion for FY2010 [3]. San Francisco has 47 sq. mi [4], so it's much less dense and yet spends over 50% more per capita.

[1] <http://www.nyc.gov/html/dcp/html/census/popcur.shtml> [2] [http://www.nyc.gov/html/dcp/html/landusefacts/landusefactsho...](http://www.nyc.gov/html/dcp/html/landusefacts/landusefactshome.shtml) [3] <http://www.nyc.gov/html/omb/downloads/pdf/sum1_09.pdf> [4] [http://184.108.40.206/search?q=cache:pRkHCezT76IJ:www.ci.sf.c...](http://184.108.40.206/search?q=cache:pRkHCezT76IJ:www.ci.sf.ca.us/site/mainpages_page.asp%3Fid%3D15216+%2Bsite:www.ci.sf.ca.us+square+miles&cd=1&hl=en&ct=clnk&gl=us)

<comment><USER20> Density lowers per capita infrastructure cost, but it also decreases tax revenues per capita. High density cities have to support the infrastructure used by commuters but can only capture a little of their tax value. During the day DC's population nearly doubles so they have to provide infrastructure for 1,000,000 people with a tax base of 600,000.

<comment><USER21> ...Except for the fact that in California, with the inability to increase Property Taxes quickly (Thank you Prop 13), an inordinate amount of revenue actually comes from commercial taxes (Sales Taxes being a large one). As a result, counties engage in a game of _discouraging_ residential zoning, and encouraging commercial zoning. I'll find a citation. [Edit - <http://www.caltax.org/MEMBER/digest/feb2000/feb00-4.htm> \- See: What are some of these side effects? ]

</comment></comment></comment></comment><comment><USER22> Fascinating article. Perhaps it's a lesson in what happens when you lack political balance? It's been fashionable in the last few years to talk about cooperation between the major parties, but to me, it's the scuffle between Right and Left that produces a government that isn't too crazy in either direction.

If a sizable number of Libertarian Nutjobs were there to fight with the Socialist Nutjobs, they'd probably be better off.

</comment><comment><USER23> NYC has good city government and one of the worst state governments in the nation. Guess it could be worse.

<comment><USER24> NYC government is high cost and plagued by unionization.

<comment><USER25> Why are people modding this guy down? I know people who are employees in the NYC system, and despite being the underlings, _they_ complain about the unionization.

The MTA, for example, apparently has more management/support than they have actual engineers working to fix things. If you went to a public school, you would have definitely heard a good number of top teachers and administrators complaining about both the BoE _and_ the teachers union.

NYC's system is _much_ worse than you'd think, but they've had two business and efficiency mayors in charge, back-to-back, trying to fix these things.

</comment></comment></comment><comment><USER26> There are plenty of poorly run and corrupt city govs. A few I've had close exposure to: Atlanta, D.C., Miami (most of south FL), Jacksonville FL (they've had a highway construction project running for over 20 years!!), Savannah GA. SF can simply get in line for the crown.

</comment><comment><USER27> Much as I hate to diss my poor suffering state all you need to look at is the five terms of Detroit mayor Coleman Young if you want to see poor leadership.

Time magazine said he is 'singularly responsible for the demise of Detroit'. San Francisco's leadership could be better, a lot better but it has a ways to go before they reach the level of Detroit's mayors and city council.

Here's a sample from a council meeting less than a year ago <http://www.youtube.com/watch?v=qqOSNI7l0bQ>

How many of the San Francisco's mayors or council have been imprisoned for selling influence?

</comment><comment><USER28> Oh man, thats funny. I know very little about SF, other than it has lots of "causers". Seems to me they keep voting for this terrible managment, so there are plenty of causes to rally for/against. Seriously half of those examples solve one problem (sending the causers home with a "we fought the good fight" feeling) only to create 2 more cause-able problems (e.g. the old-folks- home/mental hostpital overflow -- cause A: save the old people from criminals, cause B: mentally ill are people too, they need homes).

<comment><USER29> _I know very little about SF_

Pluses: It's a gorgeous city, the people are generally nice, the weather in the whole Bay Area tends to stay pretty close to perfect year round, lots of cultural variety, lots to do and see.

Minuses: the parking sucks, the traffic sucks, the myriad one-way streets suck.

In short, its a great tourist destination, but you probably wouldn't want to live there.

<comment><USER8> That's a rather generous description of the downsides of San Francisco. Parking and traffic suck in a lot of places, and the one-way streets aren't so bad once you get used to them.

The two worst problems of San Francisco are still the filth (both the rubbish- in-the-streets form of filth and the human form of filth) and the ridiculously high cost of living. The first means that you can't walk down the street for more than a couple of minutes without some weirdo either pestering you for money or trying to sell you drugs. The second means that having a reasonably nice place to live (say, a three or four bedroom detached house with a backyard -- the kind of modest middle-class dwelling that most modest middle- class families inhabit) is completely out of reach for all but the super-rich.

San Francisco is a great place to be at a certain stage in your life, but unless you do become super-rich it's an awful place to stay.

</comment></comment></comment><comment><USER14> This is because results don't matter under liberalism, only intentions.

edit: Well there are lots of reasons, actually, but I think that's one of them. I think the article makes a really profound point in passing: "Government is now paying the tab for services that used to be undertaken by families, churches — or, frankly, no one."

Now, I'm sure some of this can be attributed to the fact that San Francisco attracts a lot of out-of-towners, because of its beauty, history, jobs, etc. But I think part of it is also due to the ruling liberal ethos of radical individualism, where everyone must be free to do as he wishes without constraint (as long as he doesn't infringe on anyone else's right to do the same). Such radical autonomy must invariably involve the rejection of social obligations. After all, no one chooses into which family to be born, and most people don't choose the church they will grow up with, either. Follow this logic to its conclusion and all you're left with is democratically elected government, expressing the "will of the people".

</comment><comment><USER30> "The intrusion of politics into government ..." Yeah, I know they're not exactly the same thing, but that statement still made me laugh.

<comment><USER31> I think that could be better said as "intrusion of politics into _governance_ "

</comment></comment><comment><USER32> So, what's an example of a big city in the US that's run exceptionally well?

<comment><USER10> I read in the economist a few years ago that Atlanta is run well. Though they were comparing it to New Orleans.

<comment><USER24> Atlanta is a reasonably well run city. It gets cited a lot as a black city run by blacks that's a good place to do business.

</comment></comment></comment><comment><USER33> Miami?

<comment><USER3> I moved from SF to Miami and the government is surely corrupt here as well, but not in the same way and scale as SF.

<comment><USER34> Miami has strong opposition inside the town's political factions (new Cubans, old Cubans, retirees, etc). As far as I can tell, SF has only "radical" and "more radical" groups.

<comment><USER3> Oh absolutely. Miami's corruption is of the old school type with groups battling it out over who gets a piece of cake.

Actually there is some race factions in SF as well, mainly with the african american and chinese groups who seem to compete a bit for lucrative positions.

Ironically the lack of real difference of opinion in SF is what enhanced the failure of the city. An opposition no matter how corrupt has the incentive to call out the corruption of the other party. If all are on the same side there is no such incentive.

</comment></comment></comment></comment><comment><USER35> Uh, Detroit?

<comment> daniel-cussen Perhaps it's better run considering they have much less resources in the first place.

<comment><USER36> I don't know much about how SF is doing, but I find that highly doubtful.

San Francisco seems to be complaining about waste and bureaucracy. Those aren't healthy things.

But Detroit has been suffering massive crime, drug violence, depopulation, failing city services, depression-level unemployment, steadily falling revenue, skyrocketing illiteracy, public safety problems presented by the rotting infrastructure, plummeting graduation and has been flirting with bankruptcy for _years_.

Most of those problems were recognized problems _decades_ ago, and have only worsened.

<comment> daniel-cussen >But Detroit has been suffering massive crime, drug violence, depopulation, failing city services, depression-level unemployment, steadily falling revenue, skyrocketing illiteracy, public safety problems presented by the rotting infrastructure, plummeting graduation and has been flirting with bankruptcy for years.

Of these, only flirting with bankruptcy and failing city services are things for which city hall is responsible. The rest are not things city hall can solve. Compare it to soccer. The goalie is there to stop the other team from scoring, _but is in no way responsible for his/her team to score goals._ You can't win with just a good goalie. Likewise, a lot of what you described are problems the citizenry, and not city hall, are responsible for. I challenge the best city hall in the world to go see what it can do in Detroit; that place is a disaster anyway.

The quality of City hall is orthogonal to most of Detroit's problems, but not to San Francisco's.

<comment><USER36> Most of the other problems, the ones which I agree are not _direct_ responsibilities of the mayor and council, have grown as symptoms of those failing city services.

If you can't get your street plowed or your trash picked up, you move. If your kid isn't safe walking to, or being in school, you move. If there are no jobs in the city, you move.

The more people move, the less revenue the city gets, the more blight it acquires, the less incentive businesses have to stay in the city. Then _they_ move. The blight accelerates and exacerbates the problem of keeping those places from becoming havens for criminals, drug dealers and vandals.

Did you know there isn't a single grocery store chain in the city of Detroit? Yeah, the Eastern market and a few community gardens are stepping up to fill the void for their neighbors. But even with those, there remains a very real and serious protein problem that's only solved by leaving the city.

So, is the city directly responsible for things like the unemployment rate and drop-out rate? No. But year after year _after year_ they've ignored these problems. Refused change. _Literally_ shouted down people who have raised these issues at council meetings. Let their hatred, bigotry, sense of entitlement and corruption waylay any and every attempt to turn things around.

So, no. They're not directly responsible for kids dropping out. They are however responsible for having essentially ignored the problems in schools for the last few decades as the graduation rate has sunk to 25%. They are responsible for being so incredibly inept that the entire system was taken over by the State.

If I'm responsible for a division of programmers and our output is so consistently bad that higher-management needs to step in and address the problems - while it may not have been my personal responsibility to get code written, clearly I've not been doing a good job.

</comment></comment></comment></comment></comment><comment><USER37> "In Houston, the exact opposite of San Francisco, I assume you'd get shot"

switch that to 'small town texas' and I would agree. Houston proper tends to vote to the left, not to mention we have our own budget problems now.

<comment><USER38> Houston "proper" is a fraction of the City of Houston. (I assume you mean inside the loop.)

<comment><USER39> I would assume he meant the legal boundaries of the City of Houston, which is what the term "proper" usually means in that case.

<comment><USER38> Actually, most people in Houston tend to refer to the area inside the 610 loop in a way like the oc did. People outside 610 do not vote to the left.

<comment><USER40> I disagree with your hyperbole. I live in Montrose (very 'in the loop') and generally vote Republican. Much of my family lives in Spring (a suburb outside the loop) and vote Democrat/Green.

Houston is generally a more conservative city than SF. Overall, I feel that Houston is generally well run.

<comment><USER41> I also live in Montrose. A lot of Houston is well run. Public Transportation is a laggard, however. I spend half of my time in Minneapolis, and despite their using the same physical equipment, their public transit system is 5X better than Houston's.

I think the reason, is that in Minneapolis, it's considered a vital part of the city infrastructure. In Houston, it's a concession to the poor people.

</comment></comment></comment></comment></comment></comment><comment><USER42> US federal government? DC government?

<comment><USER43> The DC government, while still terrible, has vastly improved in the last decade, so much so that it's not even recognizable. This is reflected in the city as well, which in very large swaths are not even recognizable compared to 10 years ago (in a good way).

<comment><USER24> I don't think the actual government improved. The city turned around, but that's just because loads of crack heads finally died off, many gangsters are permanently incarcerated, and then yuppies moved in and pushed up property values.

</comment></comment></comment><comment><USER44> "The mobs of the great cities add just so much to the support of pure government as sores do to the strength of the human body. It is the manners and spirit of a people which preserve a republic in vigor. A degeneracy in these is a canker which soon eats to the heart of its laws and constitution."

Thomas Jefferson: Notes on Virginia Q.XIX, 1782. ME 2:230

(yes I will probably get down-voted on this one)

</comment><comment><USER45> I don't know if the Author has ever been to Milwaukee...

</comment><comment><USER46> I know this is schadenfreude, but I love this. As I see it, a city of people with backwards values is getting its just deserts.

Unfortunately for me, when the city eventually goes bankrupt, I'll probably end up footing the bill via my federal taxes.

<comment><USER47> Kindly elaborate why San Francisco has "backwards values". I bet you think it's an accident it's a tech innovation hub.

<comment><USER48> > I bet you think it's an accident it's a tech innovation hub.

Actually this is an accident; San Francisco's reputation as a tech hub is due to its accidental proximity to San Jose and silicon valley.

<comment><USER49> That is definitely not true. The atmos in the Bay Area is part of the reason SV is where it is.

It may well be a coincidence that SF's government is so inefficient though. Portland has the same tolerant attitude, and their city government doesn't seem to be inefficient.

<comment><USER48> > That is definitely not true. The atmos in the Bay Area is part of the reason > SV is where it is.

Right. And the "atmos" of Boston is why the high-tech hub around route 128 is where it is, having of course nothing to do with its proximity to a couple of world-class universities... The "Bay Area" may help sustain SV, but San Francisco proper is a pretty small part of that -- it is a hub of night- life/clubs, an overly pretentious literature and arts scene, and a completely dysfunctional city government. SF is a fun place to live for people of a certain age, but as the better known city in a large metropolitan region it gets far more credit than it deserves for the "atmos" that gives the region its flavor.

<comment><USER49> As in Boston, the atmos of the Bay Area is probably the main reason the universities here are so good. Universities planted in Boston and the Bay Area thrive. Those planted in cities that are bigger and richer, but have the wrong sort of culture, don't do as well. E.g. NYC vs Boston, LA vs SF.

<comment><USER48> You keep conflating San Francisco with the greater Bay Area. This mistake was my central point. San Francisco proper is a small part of the Bay Area. It has a more storied history and is the more widely-known, but it is far from being the most significant city when it comes to defining the culture and norms of the area. SF gets the press, but Berkeley, San Jose, and numerous cities up and down the peninsula contribute just as much to this tech hub as San Francisco.

<comment><USER49> When the universities' reputations were established, SF dominated the Bay Area. Till suburbia spread down the peninsula in the 1950s, what we now call Silicon Valley was mostly agricultural land.

San Jose's population in 1940 was 69,000. SF's was 635,000.

<comment><USER48> Shockley did not come to the bay area for San Francisco, he came to be close to his ailing mother in Palo Alto. From Shockley Semiconductor came the traitorous eight and Fairchild and from this cluster came most of what we now know as silicon valley. Hewlett and Packard both came from Stanford, etc.

SF may have dominated the bay area for quote a while, but none of the seminal events that can be pointed to as the seeds of what became silicon valley have a very direct link to what you and everyone else seems to consider the San Francisco "culture." The marine geography that makes San Francisco a great anchorage and led to a strong naval presence in the area probably had a bigger impact on silicon valley than anything you can point to an as a uniquely "San Francisco" impact on the valley.

<comment><USER49> The critical moment in that story was not when Shockley moved back to the Bay Area, but when the traitorous eight decided they wanted to find a way to remain here, even though they couldn't stand working for Shockley anymore. Of the eight, I believe only Moore had family here. The rest wanted to stay simply because they liked it.</comment></comment></comment></comment></comment></comment></comment></comment></comment></comment>


Haskell Data Analysis and Machine Learning Cookbook - <AUTHOR> http://haskelldata.com/ <comment><USER3> I like seeing more things come out helping people with data analysis in various languages, but this put me off:

> isWhitespace x = elem x " \t\r\n"

This is the kind of thing that makes me concerned about using this resource for real-world data. In real-world data you're going to get all kinds of crazy things coming in, and if you're assuming nobody will ever have something like a zero width non-breaking space, or a form feed, you're going to have a problem.

It's the kind of thing I see with people starting out when dealing with data, similarly the punctuation detection here: [https://github.com/BinRoot/Haskell- Data-Analysis-Cookbook/bl...](https://github.com/BinRoot/Haskell-Data- Analysis-Cookbook/blob/master/Ch02/Code02_punctuation/Main.hs)

If you rely on these things, you will have problems. Text is hard and weird and terribly more complicated than people usually expect.

Does haskell have good libraries for dealing with the more awkward parts? Can I easily remove all characters marked as whitespace in unicode, for example? Detecting and managing mangled encodings?

<comment><USER4> That line of code was demonstrative. The actual book uses 'Data.Char.IsSpace' which properly handled it.

"Returns True for any Unicode space character, and the control characters \t, \n, \r, \f, \v."

Before you chastise them for not handling something, verify it. I'm not affiliated with the book but you probably deterred people from buying it.

[https://github.com/BinRoot/Haskell-Data-Analysis- Cookbook/bl...](https://github.com/BinRoot/Haskell-Data-Analysis- Cookbook/blob/master/Ch02/Code01_whitespace/Main.hs)

<comment><USER3> Well for one the line shouldn't really be one of the first bits of advertising for the book if the author also knows it's wrong. The second example is taken from the GitHub repo for the book though, and is exactly the same type of error.

> you probably deterred people from buying it.

Quite possibly, but I think with good reason. I don't know what's in the book but I'm concerned it won't contain things like a discussion of what whitespace is and is not, how to decide what you should do for your data and when isSpace might not do what you really need. I can't review it properly but at least one bit of code in the repo looks dangerous and one bit on the website looks dangerous.

</comment></comment></comment><comment><USER5> This is a repost of a book we published in 2014. It's well reviewed, and the author kept the Github repo for the code up to date with feedback ([https://github.com/BinRoot/Haskell-Data-Analysis- Cookbook](https://github.com/BinRoot/Haskell-Data-Analysis-Cookbook)). If anyone wants to try it, you can pick it up in the Packt sale currently for $10 @ packtpub.com

</comment><comment><USER6> I have bought that book some years ago and wouldn't do so again. It was very disappointing to see neither a focus on Haskell nor on data analysis. It scratches both topics but covers only very elementary things. The content is mostly short receipts that were to me of no value at the time.

For people interested in the topics I'd recommend to buy some other good books, on Haskell and data analysis separately.

If, however, receipts are to your liking and you're only starting out with Haskell / data science maybe this is something for you (or maybe not).

</comment><comment> blubb-fish Serious question:

Is there any reason why somebody would use Haskell for data analysis when there is also R and Python - which are perfect for that job - except for that the respective person happens to be a Haskell expert anyway?

<comment><USER7> I use all three, depending on the task. Haskell is compiled and relatively speedy, as well as being great for writing custom parsers (plus in a lot of situations it parallelizes very easily). One thing I find Haskell to be really useful for is coercing large unstructured datasets into a format that is easier to feed into Python.

For instance, I once had to write a parser for the data coming off of a digitizer being fed by a rather complicated radiation detector array. It's in an obscure and somewhat bizarre binary format that is pretty tedious to work with because it involves a lot of state in the parser, plus the files are pretty enormous (they describe every radioactive particle hitting every detector in the array over several hours of measurement). My colleague wrote a horribly tedious script in Python to parse it that was complicated and agonizingly slow, but I was able to write a very natural 80-line Haskell program in a few hours that was several orders of magnitude faster as well as much more robust. I was just massaging the data to feed into Python, but it was far far easier to do in Haskell.

So I find for some tasks I want to reach for Haskell, because it's natural to express the solution in Haskell. Other stuff I wouldn't even consider it, especially for stuff like data processing and plotting Haskell is not as elegant. Right tool for the job and all.

<comment><USER8> This 80-line solution sounds very interesting. I'd love to see more examples of this particular strength of Haskell. Are there similar parsing projects that you can point to that are open source and worth looking at to better understand this use case of Haskell?

<comment><USER9> Here is an example from Real World Haskell (pretty good intermediate book, although it is a bit dated): [http://book.realworldhaskell.org/read/using- parsec.html#csv](http://book.realworldhaskell.org/read/using-parsec.html#csv)

A fully featured CSV parser in 20-30 [depending on how you count] lines of non-golf code.

<comment><USER8> I'm curious what aspects of Haskell have changed to cause this book to be dated, i.e. are there examples in this book which would be done differently now?

<comment><USER10> This SO thread is very informative in this regard: [http://stackoverflow.com/questions/23727768/which-parts- of-r...](http://stackoverflow.com/questions/23727768/which-parts-of-real- world-haskell-are-now-obsolete-or-considered-bad-practice)

</comment></comment></comment></comment></comment></comment><comment><USER11> It definitely seems like there's a lack of intermediate-to-advanced Haskell books. This looks like it contains a lot of canonical Haskell coding examples and might be useful: any Haskell experts that can weigh in?

The other Packt Haskell book is apparently terrible, so I'm a bit cautious.

<comment><USER12> This is my favorite resource: [http://haskellbook.com/](http://haskellbook.com/)

It covers beginner topics through arguably advanced topics (monad transformers, etc.)

"Advanced" is subjective, but I don't believe the current version covers GADTs, type families, or other more esoteric extensions.

(No affiliation to the authors)

<comment><USER13> I've seen GADTs as a feature that Haskell devs complained about, similar to Template Haskell. I know the issues with TH, but what's the limitation of GADTs as implemented in Haskell, and are there languages with less problematic implementations?

<comment><USER14> Maybe some people think they're a little complex, but there's nothing particularly wrong with them in Haskell. They can be extended further in a dependently-typed context, but that's really another thing completely.

</comment></comment></comment></comment><comment><USER15> I bought this book a couple of years ago and never read through it. It does provide convenient recipes that you can look up in the table of contents. I like recipe books like this, but be warned that there is not much depth. I recently bought another book by the same author that is also useful.

</comment><comment><USER16> BTW, one might notice how a language with type-tagged data (a value has a type, not a variable, there are no box-like variables, but bindings) is much more suitable for data exploration and analysis (python + pandas is a good example).

Also homogeneous lists and especially conditionals is kind of awkward - <USER2> aren't as flexible as lists. Defining a type for each possible row and then pattern-match on will result in a lot of useless boilerplate, almost as bad as Java.

Common Lisp, it seems, is a better choice for such problems.

<comment><USER17> The dependently-typed-ish features of haskell can provide a sweet spot of both untagged data along with the flexibility of heterogeneous lists.

<comment><USER18> An example / reference would be nice.

</comment></comment></comment><comment><USER19> I might have a look, but the page seems to be a big ad with animated buy buttons at top?

I posted a link for a free online kdb training class 3 months ago for students that normally goes for $1300 with no affiliation to the company, and it was flagged. What's the difference?</comment>


Using the Pipo X9 mini-pc as a tabletop SDR receiver - <AUTHOR> http://phasenoise.livejournal.com/5190.html <comment><USER2> I would build a platform for the unit to sit on and a power pack for portable use.

<comment><USER3> So, something like this [0]?

I saw it the other day and found it interesting, but not that useful to me.

[0] [https://www.indiegogo.com/projects/ockel-sirius-a-the- world-...](https://www.indiegogo.com/projects/ockel-sirius-a-the-world-s-most- versatile-mini-pc-mobile-design--2#/)</comment></comment>


How *NOT* To Do A Password Field - <AUTHOR> http://shkspr.mobi/blog/2014/04/how-not-to-do-a-password-field/ <comment><USER2> > If you have to restrict the length, use maxlength in the input field.

The problem with this approach is that, for longer passwords, the user may not be aware that the maxlength property has prevented the field accepting the last n characters of their password. They may believe they have successfully submitted their entire password. In other words, they may believe their password is

      i_love_peanut_butter_and_j3lly

but it's actually

      i_love_peanut_butter_a

This may work for a time, but is likely to cause problems down the road.

</comment><comment><USER3> > Don't let a user submit a password which doesn't meet your requirements. Use > JavaScript to disable the button and highlight the text of your password > policy.

If you are going that route, please change last line to:

"Use JavaScript to disable the button and highlight the text of your password policy (in addition to server-side validation)."

However, consider using a "poor password", "good password", "great password" approach that changes as you type and don't have a short max length in your validation, this way you can promote entering sufficient complex passwords of longer length. The best of these I've seen is a "progress bar"-looking thing under the password fields that also uses color changes (just don't use green as bad and red as good, and be aware of color-blindness/blindness) and text under it to describe how good or bad the password is.

Here is one of Microsoft's recommendations. It looks a lot like the cartoon in the post: [http://technet.microsoft.com/en- us/library/cc786468%28v=ws.1...](http://technet.microsoft.com/en- us/library/cc786468%28v=ws.10%29.aspx)

That helps but is far from good enough. Read: [http://en.wikipedia.org/wiki/Password_strength](http://en.wikipedia.org/wiki/Password_strength)

Focus a bit on entropy to go with that colored-progress bar I talked about:

"It is usual in the computer industry to specify password strength in terms of information entropy, measured in bits, a concept from information theory. Instead of the number of guesses needed to find the password with certainty, the base-2 logarithm of that number is given, which is the number of "entropy bits" in a password. A password with, say, 42 bits of strength calculated in this way would be as strong as a string of 42 bits chosen randomly, say by a fair coin toss. Put another way, a password with 42 bits of strength would require 242 attempts to exhaust all possibilities during a brute force search. Thus, adding one bit of entropy to a password doubles the number of guesses required, which makes an attacker's task twice as difficult. On average, an attacker will have to try half of the possible passwords before finding the correct one."

Following on that with: [http://en.wikipedia.org/wiki/Entropy_%28information_theory%2...](http://en.wikipedia.org/wiki/Entropy_%28information_theory%29)

That states the limitations thereof, so entropy alone is not good enough:

"Limitations of entropy as a measure of unpredictability

In cryptanalysis, entropy is often roughly used as a measure of the unpredictability of a cryptographic key. For example, a 128-bit key that is randomly generated has 128 bits of entropy. It takes (on average) 2^{128-1} guesses to break by brute force. If the key's first digit is 0, and the others random, then the entropy is 127 bits, and it takes (on average) 2^{127-1} guesses.

However, entropy fails to capture the number of guesses required if the possible keys are not of equal probability.[17][18] If the key is half the time "password" and half the time a true random 128-bit key, then the entropy is approximately 65 bits. Yet half the time the key may be guessed on the first try, if your first guess is "password", and on average, it takes around 2^{126} guesses (not 2^{65-1}) to break this password.

Similarly, consider a 1000000-digit binary one-time pad. If the pad has 1000000 bits of entropy, it is perfect. If the pad has 999999 bits of entropy, evenly distributed (each individual bit of the pad having 0.999999 bits of entropy) it may still be considered very good. But if the pad has 999999 bits of entropy, where the first digit is fixed and the remaining 999999 digits are perfectly random, then the first digit of the ciphertext will not be encrypted at all."

But, even checking for common passwords (search and you can find numerous articles on that), etc. is not good enough. You must also tell people not to use easily guessable personal information in their passwords. Your birthdate, then "$" then your son's name then "$" then his birthdate may have "ok" entropy, but it would be easily hackable for anyone with elementary knowledge about the person.

That starts to get into the fallacy of security questions to reset your password, though. Security questions are terrible, and I cannot believe that financial institutions use them. If you hack the email account and know enough personal info, you bypass the password. That's bad.

But, everything is hackable, eventually. There are no hard rules that cannot be broken. Even our understanding of physics, etc. is incomplete. Anything is possible.

</comment><comment><USER4> Actually, please do NOT have a maxlength on your password field. Instead, if the contents are too long, disable the submit button and tell me my password is too long. Why? Because I never actually _type_ in a password. I generate a long one and copy & paste it in. And when you put a max length on the field, I think my password is FooBarBazBatAwesome, and you think my password is FooBarBazBat.... and that is going to _screw me_.

I've had this happen on more than one occasion. For God's sake, do not put a max length on your password field. It silently drops any characters that are too long without notifying the user that it's doing so.

</comment><comment><USER5> > If you have to restrict the length, use maxlength in the input field.

This bit is really bad advice. Maxlength stops you from typing but doesn't give you any indication it's happening, so I'd be happily typing out a 20 character password without realizing it's being lopped off somewhere.

If they ever lift the maxlength restriction, my password suddenly stops working for no apparent reason.

<comment><USER4> Ha! Glad someone else agrees :)

</comment></comment><comment><USER6> YES!!!! TELL US THE DAMN PASSWORD RESTRICTIONS ON THE FORM BEFORE THE PASSWORD IS ENTERED!!

I hate hate hate hate (can't you tell I really hate it) when I use LastPass's awesome password generation, only to save and submit and then be told by the site the password is bad for whatever reason.

Please just do this. THEN we can start talking about those other restrictions (why is my password limited to 16 or even 32 characters?!?!).

Lots of frustration here, I'm pretty certain it's shared by a lot of people. Does feel better though :)

Now I'm not a web dev but I'm interested and echo the question that someone else posted below - why is there a length restriction on passwords (notwithstanding a restriction to stop strain on the server)?

</comment><comment><USER3> On a related topic, a troubling new trend (to me) is the reliance on passwords being automatically generated/kept by a tool. You are putting your trust in something else for something only you (or a select group) should be trusted with. If everyone were to start doing this or a vulnerability was found in it and exposed, then attackers would exclusively target the tool or the password store, making many at risk.

It is a trade off, because you have the ability to use significantly more complex passwords that are harder to brute force or guess using personal information. Just don't forget that you are providing new attack vectors in the process. If they access your password store and you didn't know about it, how at risk would you be if they were to unlock all of your passwords?

Do you really understand how the password store and password generator work?

</comment><comment><USER7> The problem with really awful password interfaces lies mainly with big institutions (banks!) who are unlikely to be influenced by bloggers linked on hacker news.

Ever since switching to a password manager (1Password in my case) I've become acutely aware of how many places have ridiculous restrictions on passwords (especially _maximum_ lengths and character restrictions), and the worst offenders are invariably banks and financial sector sites.

<comment><USER8> It seems like the more secure you need your data to be, the worse their password restrictions are. Restrictions such as no special characters, or an arbitrary short length raises a red flag. It says they don't really know what they are doing, and it makes me wonder what else is broken.

<comment><USER9> And no SQL keywords allowed in passwords. Because they like to advertise that they don't bother escaping user input before concatenating sql strings to store plain text passwords in the database.

[http://stackoverflow.com/questions/13738141/blacklist- filter...](http://stackoverflow.com/questions/13738141/blacklist-filtering- data-for-sql-keywords)

<comment><USER10> I'd bet that patterns like

        $db->execute("INSERT INTO USERACCOUNTS ('username','password') VALUES ('".$_POST['username']."','".$_POST['password']."')");

are more common than anyone wants to believe.

<comment><USER9> The PHP manual pages are full of user comments with helpful suggestions just like that, which incompetent programmers copy and paste into production systems. But I think of it as a good thing, an instance of evolution in action, because banks that hire such stupid programmers deserve to have all their money stolen from them.

</comment></comment></comment></comment></comment><comment><USER11> If you _must_ have a maxlength, please be sensible. I've seen plenty of sites use 12 as max length - which is really not that much.

Also, requirements to what characters must be used (at least one number, at least one upper case letter) doesn't do much to increase security I think. Just let me enter whatever I want.

</comment><comment><USER12> I hate sites that restrict how complex my password can be. Seriously, NemID, a Danish ID every person has that's used for everything (banking, among other things), don't allow special characters. What the heck. It's like they want it to be insecure.

</comment><comment><USER13> _Why_ would you have to restrict the length at all? I could see something like a few thousand characters max, to avoid making it easy to strain the server, but other than that, you're not supposed to store it as is anyway, and if you hash it, the input length doesn't really matter... what am I missing?

<comment><USER10> You're missing the obvious - that such restrictions are a sign the site does probably store passwords in plaintext.

Although _maybe_ they aren't but they still want to make sure they meet some arbitrary standard of "randomness" to make it less "hackable."</comment></comment>


Student Who Found GPS Device On His Car Due To Reddit Comment Sues The FBI - <AUTHOR> http://www.techdirt.com/articles/20110304/10254213366/student-who-found-gps-device-his-car-due-to-reddit-comment-sues-fbi.shtml <comment><USER2> For my little branch of this comment thread, can we leave aside the FBI's reason for planting a GPS monitor? Just assume the FBI had no reason whatsoever. That they did it randomly. I tend to agree that in this case, they didn't seem to have a good reason. But, then:

Exactly what is the damage this guy suffered? What's he suing over?

Why should it be unconstitutional for the FBI to use technology to do something they can _clearly_ already do without technology? It is not a violation of your civil rights for an unmarked car to follow you around and watch you.

There clearly is a line here, so let me foreclose on that response right up front. Yes, it would be unconstitutional if the FBI tried to track all of us, by making coded GPS monitors mandatory on all cars.

But in this case, if they couldn't plant the monitor, they could just follow him. He'd have no case. It's almost exactly the same loss of privacy. So why it such a big deal in the GPS case?

<comment><USER3> >Exactly what is the damage this guy suffered? What's he suing over?

That's what we are trying to find out! He was being spied on because he has a foreign sounding name -

is he now on a no-fly list? is he on a secret do-no-hirelist for defense companies? for telecoms companies? for any companies with govt contracts? Does the FBI secretly OK who state colleges accept?

If being secretly tracked by the secret police is no real damage - at what point is there damage? When the cattle trucks arrive ? Or when they get over 6Million

<comment><USER4> > That's what we are trying to find out! He was being spied on because he has > a foreign sounding name

That's the worst part, fixating on such a useless thing.

Imagine if the US and Canada went to war, I as a Canadian of Irish heritage could easily blend in, meanwhile the French with accents would be targeted. Meanwhile the people who don't fit a stereotype are planting bombs.

It's incredibly unprofessional, amateurish and ignorant for government security agents to use such superficial reasons to think a person is a threat.

<comment><USER5> >It's incredibly unprofessional, amateurish and ignorant

I think the term you're looking for is "Bayesian," actually.

</comment></comment></comment></comment><comment><USER6> If this is how they react to a comment on Reddit, just think of how much quicker or more drastic their reaction to a similarly provocative comment on a site with the ominous name _Hacker_ News.

("ominous name": Although the word _Hacker_ is not ominous to most of us, it is to almost all non-technical members of the Washington establishment.)

<comment><USER7> Prosecutor: "Is it true Mr. Hollerith that you self-identify as a hacker and that you frequent a community of hackers known as Hacker News?"

You: "Yes, but..."

Prosecutor: "A simple yes or no will suffice."

You: "There are questions that can't be answered with a simple yes or no. For example, you could ask me if I have stopped beating my wife."

Prosecutor: "Have you, Mr. Hollerith?"

In short, a jury of "peers" is not going to be comprised of peers. On average they are people who have a poor grasp of logic, statistics, and the personality of hackers. They'll judge you based on the way you look, talk, etc... And since you are all Mr. Smarty Pants, members of the average jury will not trust you, like you, or relate with you. As such, hacker types have a major disadvantage in court, even before tossing around labels that are considered as "shady" by the general public.

<comment><USER8> Is it permissible in American courts to require the prosecutor to unambiguously define "hacker" before answering?

If not, can you feign ignorance of the definition and explain that you are thus literally incapable of providing an honest & informed answer; and since you are under oath, require a definition before answering?

<comment><USER9> "It depends upon what the meaning of the word 'is' is."

</comment></comment></comment></comment><comment><USER10> All these goof-ups by the FBI don't paint a pretty picture about the agency at all and I'm surprised some news agency isn't up in arms about their funding and incompetence like they are with the teachers' unions.

<comment><USER11> _All these goof-ups by the FBI don't paint a pretty picture about the agency_

Do you mean the agency founded by J. Edgar Hoover?

[https://secure.wikimedia.org/wikipedia/en/wiki/J._Edgar_Hoov...](https://secure.wikimedia.org/wikipedia/en/wiki/J._Edgar_Hoover)

Its founding principle was that there are baddies out there who need a special force of investigators who have powers far exceeding the regular police and who collect dossiers on suspicious citizens rather than simply waiting for crimes to occur and then investigating.

In a certain sense, they aren't being incompetent, they're doing exactly what they were designed to do. The problem isn't the execution, it's the mandate.

Here's another tidbit:

<https://secure.wikimedia.org/wikipedia/en/wiki/COINTELPRO>

<comment><USER10> I have no problem with the mandate. It's the clear lack of competence in intelligence gathering that bothers me. Who honestly considers anything said on reddit to be of any significant value to state security matters? They might as well throw a dart on some board and make decisions that way if they are so desperate as to use postings from reddit.

</comment></comment></comment><comment><USER12> I'm sorry I'm late to this discussion, but: some people seem to be saying, "what's the harm? what damage did he suffer?".

I'd like to point them to Kyllo -vs- United States <http://en.wikipedia.org/wiki/Kyllo_v._United_States> . Basically, the USSC ruled that taking a thermal image of a house amounted to "unreasonable search". Even though the heat rays emanating from the dwelling can be considered "public knowledge", the cops can't use it to then conclude that there's a grow op in the house.

So, just because something is sorta "public" it doesn't mean the cops can reach for it.

<comment><USER13> Wouldn't it be a little scary finding such a device in your car? At first, you might wonder if it's linked to a a bomb. Then if you consider it's a tracking device, who is actually following you? I'm sure it's enough to give some people at least moderate anxiety and others possible severe. Who knows what else.

</comment></comment><comment><USER14> actual and better source: [http://news.yahoo.com/s/ap/20110303/ap_on_re_us/us_gps_track...](http://news.yahoo.com/s/ap/20110303/ap_on_re_us/us_gps_tracking_warrants)

<comment><USER15> Much better source.

" _His lawyers say Afifi, who was born in the United States, was targeted because of his extensive ties to the Middle East — he travels there frequently, helps support two brothers who live in Egypt, and his father was a well-known Islamic-American community leader who died last year in Egypt._ "

This is part of the story that TechDirt left out in favor of the inflammatory but misleading man-persecuted-over-Reddit-comment angle.

<comment><USER16> Replace the words with whatever country is 'scary' to you, and you've got probable cause!

 _"His lawyers say Wing, who was born in the United States, was targeted because of his extensive ties to asia — he travels there frequently, helps support two brothers who live in China, and his father was a well-known Asian- American community leader who died last year in China."_

Ridiculous... racism is not probable cause.

<comment><USER17> >"well-known Islamic-American community leader"

This sort of comment I always assume is double-talk (government-ese maybe) for someone who they know has close ties to terrorists. I'm guessing one of the family has been undertaking some "terrorist" activities and that makes it look bad for Afifi as he's sending money home. Of course this is speculation and Afifi himself wouldn't likely know if it were true or not so I have no way of knowing either.

<comment><USER18> Martin Luther King was a "well-known Christian-American community leader". That's how you should read it.

That you think otherwise means they already managed to indoctrinate you that far, to accept the seeds of doubt and mistrust they try to plant. That way, however it turns out, they are always right.

<comment><USER15> _That's how you should read it. That you think otherwise means they already managed to indoctrinate you that far..._

What doctrine are you beholden to that gives you the right to declare someone "indoctrinated" if they don't interpret things exactly as you do? Is no man free to think for himself?

</comment></comment></comment></comment></comment></comment><comment><USER19> What I don't get is why he had to give it back. Since the FBI stuck it to his car isn't it his now? When they came to demand it back he should have refused. Are they going to arrest him for harboring stolen property? They gave it to him.

<comment><USER20> If I recall correctly he did ask for proof that it was theirs before he would hand it back, but I seem to remember they refused and basically threatened him into returning it.

<comment><USER21> What would they do to him if he just destroyed it as a suspicious, unknown, but potentially dangerous object?

<comment><USER22> Or had "accidentally" dislodged it and attached it to a freight truck.

<comment><USER8> "Jeez. This guy really drives a lot, for a student."

</comment></comment></comment></comment></comment><comment><USER23> He didn't find it "due to Reddit."

His mechanic noticed it when doing maintenance work (it was hidden improperly and was an older, bulkier model). Then the kid posted a picture of it to Reddit and asked what it was. Shortly after the FBI showed up at his house and asked for it back.

<comment><USER24> I think the headline is supposed to mean that the GPS device was on his car due to a Reddit comment.

It is a really awkward headline though.

</comment></comment><comment><USER25> Leaving aside the particulars of this case since all we've heard so far is what his lawyers are saying happened, the troubling issue here is that somehow attaching a GPS device is an action that does not require a warrant.

I can accept the argument that it doesn't gather information that couldn't be gathered by other warrantless activity such as following him with agents.

But it also MUST require that they entered the personal property of his car. You can't search a car without consent or a warrant, why can you enter it without either?

</comment><comment><USER26> If they can plant a GPS in your car, what will stop them from planting a microphone or video camera in your bedroom? Wiretapping is so common nowadays that we don't even complain any more.

</comment><comment><USER27> The consensus here seems to be that the FBI crossed the line from passive to active tracking, and should have needed a warrant, when they entered his property to place the GPS device into his vehicle.

Tracking you by something like GPS on your cell phone doesn't require physical interaction with your property. The effect is similar, though. What's the difference?

</comment><comment><USER28> Open information systems (the internet) leads to all sorts of changes in closed system (Middle Eastern governments, State Departments, the FBI). The internet is fun again.

</comment><comment><USER29> Not sure if I missed it but what was the comment he posted that flagged him to the FBI?

<comment><USER30> This was actually his friend's comment on Reddit.

[http://www.reddit.com/r/AskReddit/comments/ciiag/so_if_my_de...](http://www.reddit.com/r/AskReddit/comments/ciiag/so_if_my_deodorant_could_be_a_bomb_why_are_you/c0sve5q)</comment></comment>


The New New Economy: More Startups, Fewer Giants, Infinite Opportunity - <AUTHOR> http://www.wired.com/culture/culturereviews/magazine/17-06/nep_essay#

<comment><USER2> I don't understand what this article is trying to say. Will the internet magic away the infrastructure necessary to manufacture a car? Will it make the massive cost of developing and testing a new drug disappear?

The money for these things has to come from somewhere. Venture capital is an option, but that's an all or nothing proposition. Larger companies can fail and live to fight another day. There's obviously a motivational benefit to failure not being an option, but that doesn't guarantee success. Likewise, large companies tend to ossify and become numb to failure, but that doesn't guarantee their collapse.</comment>


Making the Case for Eating Fruit - <AUTHOR> http://well.blogs.nytimes.com/2013/07/31/making-the-case-for-eating-fruit/?src=me&ref=general&_r=0

<comment><AUTHOR> I find this article interesting as I have a vague recollection of some paleo- types on here equating eating an apple to eating a candy bar. "It's the same amount of sugar!" they naively say.</comment>


Canada, Tomorrow's Superpower - <AUTHOR> http://www.bloombergview.com/articles/2015-06-12/canada-might-have-the-goods-to-become-a-superpower

<comment><USER2> Two out of the three points mentioned are not applicable anymore: good government and open immigration policy. Canada just thist past week introduced a second class citizenship which can be revoked at the mercy of a Citizenship Officer if they deem that I am not intent on staying in Canada. So for example if I go work in US, my citizenship can be taken away.

This ofcourse was introduced by the current corrupt Harper government and can be aimed at liberals who oppose government plans to sell off our natural resources to oil and water companies for peanuts at a high risk to its citizens.

Anyone wanting to immigrate to or open business in Canada, think twice, as this is not the same country you once knew.

<comment><USER3> I don't know all the details of bill c51, but I read about the citizenship changes that apply to dual citizens.

They're not going to revoke citizenships because you work in the US. They will revoke them from people who fought in armed conflicts against Canada, from people charged with terrorism related offenses in their home countries, and from people who intend to commit acts of terrorism.

What you've said is incorrect. There's a lot in bill c51, but no-one intends to use it against someone who works in the US.

<comment><USER2> BTW, it's not just for dual citizens. It's for all naturalized citizens also. In fact, you can lose your citizenship even if you're born in Canada, but can potentially qualify for some other country's citizenship through your parents. It's all levels of fucked up.

<comment><USER3> Yeah, I fall under one of the categories of people who can lose their citizenship.

I know I won't lose my citizenship. The people who this will be used against aren't the kind of people I want to share Canadian citizenship with. Say someone who was born here, and had another citizenship, joins ISIS, and isn't allowed back? I'm OK with that.

If I read that they died in the desert (this actually just happened to few guys from Canada), I'd shake the guy who pulled the trigger's hand.</comment></comment></comment></comment>


What it's like to spend four and a half years in solitary confinement (2015) - <AUTHOR> https://fusion.tv/story/216609/shaka-senghor-solitary-confinement/ <comment><USER2> I generally like being alone in my room. My desk, tv, and bed are within 10 feet of each other. And I have never really put anything on my walls. Just white walls, desk, bed, and tv. I have been in a basement for the last 18 months and I have been upstairs for about 5 minutes today. I have a bathroom and fridge and microwave down here.

But I have a feeding tube. That is how I ended up down here. We thought it would be the safest place to be while I was going through chemo. For six months while my immune system was garbage I just stayed down here and would only go up to get groceries or go to chemo/radiation. So I always joked that I think I could deal with solitary. I prefer being alone.

All that changed about a month ago.

The balloon on my PEG tube (DDG it) had deflated. And one night I went to change the gauze and while I pulled the gauze out it just started pouring out blood. In a matter of seconds my boxers had blood all over them. I was terrified. This much blood on the outside, how much blood is going into my stomach? Am I going to bleed to death? On the ride to the ER I was feeling faint..

I am getting to the solitary part.

But I saw a nurse right after checking in. And she determined I wasn't bleeding to death. I was going to have a bit of a wait to see a doctor. 4 hours to be exact. But they wanted me out of the ER waiting room due to being on pembro and there had just been a case of C-19 8 hours away.

So I was being walked to a room and she said they were low on places to put me. I was going to be in a "mental health" room. But they got a bed in there for me. White walls, a bed, no problem..

Huge problem!

It is so hard to describe. It was basically a cinder block box and a massive metal door. Everything tucked away so you couldn't kill yourself. And it was so loud since the air had to be pumped in. And I had a bed they wheeled in for me. And the door was open so I could go to the bathroom when I wanted. If that door was closed and I couldn't get out I would have lost my shit. And I nearly lost it anyway. Something about that room was just unlike anything you can imagine. It was like being buried alive.

I would imagine solitary is about a million times worse. I would classify it as torture.

And my feeding tube had slipped between my stomach and the "outside skin" tearing up everything making it bleed. Just shoved it back in and loaded up the balloon with more saline and went home. And then had the tube replaced the next day during normal hours.

<comment><USER3> Thanks for the story, and the perspective. I appreciate it.

Obviously it means nothing over the internet but I'm sitting here hoping the best for you. Good luck, man.

</comment></comment><comment><USER4> It's absolutely cruel and unusual punishment. The American Constitution forbids this. I've only spent three days straight in a county solitary cell for a silly threat to a judge. In that scenario, it was a glass walled cell in the high security block. Every surface is cement, and your only clothes are a Velcro tunic/blanket. Surveillance is continuous. There, the non-compliant were beaten and strapped to a wheelchair for days and not their bed. They also open your cell to let a violent offender "clean your cell for you" on a regular basis. It was awful in a way entirely unto itself in my memory. I can't even begin to imagine the conditions and lengths of time in this article.

<comment><USER5> You were in solitary confinement but had another offender come in there daily to clean the cell while you were there? I was under the impression that solitary confinement didn't allow interaction with others.

<comment><USER6> No cleaning. Beating.

</comment></comment></comment><comment><USER7> Why no comments discussing the root cause has the writer reported it: men who should be receiving non-voluntary mental treatment being forced into the prison system due to non-existence of mental facilities.

Historically said mental facilities (mental asylums) were themselves inhuman and barbaric. The out cry against them lead to their closure. Yet if that just drove the prison system to new levels of inhuman and barbarism then that itself a regression.

Do other countries have more successful mental services? I know Japan did not close down their asylums during the same era America did. Are those facilities acceptable?

<comment><USER8> What lead to their closure in US was Reagan's defunding: [https://www.salon.com/2013/09/29/ronald_reagans_shameful_leg...](https://www.salon.com/2013/09/29/ronald_reagans_shameful_legacy_violence_the_homeless_mental_illness/amp)

<comment><USER9> It's bigger than Ronny Raygun. The first problem was JFK died before the community-based treatment centers could be funded and realized. Subsequent presidents scaled them back because they didn't understand or couldn't relate to their need. And so, Cook County (encompassing Chicago) jail run one of the largest mental healthcare systems because state, local and federal government has failed to do so.

EDIT: forgot the word "jail"

<comment><USER8> Agreed. There was an article on HN about the demise of psychiatric care in US written from the inside by a psychiatrist. I can't find it though.

It was about defunding and kicking the problem between the federal level and the states.

<comment><USER9> The ol' finger-pointing, can hacky sack-routine rather than helping the people who can't adequately grasp reality or hold jobs are left to live in tents in the weeds of highway embankments or under bridges. TBH, this seems like something some social-work lawyers should take on to push federally through the courts or with legislation. Worrying about initial sticker-price shouldn't be the focus because of the numerous ancillary costs that are far more expensive than doing the right thing (which is why Cook County jail does what it does).

</comment></comment></comment></comment></comment><comment><USER10> Unfortunately the US (no doubt others too) prison is the business of punishment. If you are poor you will get a harsher punishment. If nobody is looking you will get a harsher cheaper punishment. Working at a prison requires a certain mindset. Empathy is soon weeded out. What's left is brutality. That's the deal society has made, to hide away the hard problem of solving crime at root cause.

</comment><comment><USER11> The issue is that we still treat prisons as a medieval revenge tool instead of a reinsertion phase for the prisoners.

American prisons are a shame and there is absolutely no way that convicts come out of it ready to participate to society.

This youtube channel gives a good perspective on how inhumane life is in American prisons: [https://www.youtube.com/channel/UCzmkeda2XiYpETOP5MjotrQ](https://www.youtube.com/channel/UCzmkeda2XiYpETOP5MjotrQ)

<comment><USER12> Its not just prison, it's the entire perception of crime and punishment in the US.

Its why convicts cannot vote in elections even when they get released.

Its why they still have the death penalty. And why victims families can watch them being executed. Its eye for an eye, punishment and not forgiveness and rehabilitation. Its much deeper than the quality of life behind bars.

<comment><USER13> > Its why convicts cannot vote in elections even when they get released.

Just felons, not anybody who's been convicted of a crime. Not justifying it, just making the distinction. I still believe it's wrong.

<comment><USER14> Felons not being able to vote is not universal. It is up to each state to determine whether to allow felons to vote. In recent years restoration of voting rights to felons has been on the rise.

<comment><USER13> An important clarification, which furthers my point that "convicts can't vote" is pretty inaccurate.

</comment></comment></comment></comment></comment><comment><AUTHOR> Also, here's his book: [https://www.amazon.com/Writing-My-Wrongs-Redemption- American...](https://www.amazon.com/Writing-My-Wrongs-Redemption- American/dp/1101907312)

</comment><comment><USER15> Big money from few players

[https://en.wikipedia.org/wiki/GEO_Group](https://en.wikipedia.org/wiki/GEO_Group)

[https://en.wikipedia.org/wiki/CoreCivic](https://en.wikipedia.org/wiki/CoreCivic)

<comment><USER16> Would be no shame if some of those people ended up in the places they operated for profit.

</comment></comment><comment><USER17> It's obviously torture. If you've ever spent one night in a holding cell/mental health hospital situation you know it's absolutely 100% inhumane. It's only nazis who've never been in that situation who think like "oh well we have to do something with people like that you know". We have to help them, not lock them in a fucking box. It's a heinous crime committed every single day by the state and complicit officials. Should be abolished today.

</comment><comment><USER18> Eva Zeisel is an important American designer. She also happened to be my next door neighbor. Over dinner, she recounted her 12-months in solitary confinement in Siberia, for having protested against Stalin's regime. She has written a bit about this experience.

She was 97 when I knew of her and even though she was ageing, her faculties were sharp (Extra Pepperoni is the only way to have a Slice, she said).

I asked her what lessons from the Solitary confinement stayed with her. She said "The value of knowing that there was no yesterday and probably there will be no tomorrow. And somehow I need to resist the urge to use, the intentionally left behind blunt knife to cut my veins. And the value of dressing warm".

I cannot even imagine what it must have been. She was some human.

[https://en.wikipedia.org/wiki/Eva_Zeisel](https://en.wikipedia.org/wiki/Eva_Zeisel)

</comment><comment><USER19> You can measure the health of a society in how they treat the weak and helpless (helpless in this case in regards to prisoners who are at the whim of the prison).

In this regard, America is profoundly sick and defective.

It is of course true, instead of rehabilitating, they are breeding criminals in prison. It's an abomination.

</comment><comment><USER20> > I began to carry a gun every day, dealing with the PTSD issues, and fourteen > months later I shot a man and unfortunately caused his death.

He doesn't really seem to want to take responsibility for killing someone. I am sure solitary is terrible, but so is being killed by someone like him.

<comment><USER21> That is really besides the point, because this article is about the third world, or should I say medieval prison system in the USA. That system is a crime against humanity in far too many ways. It is just one of the things many Europeans just don't get why you think it's acceptible. The prison system in the USA is a major cause of crime, not a solution. No civilized country has jailed up anywhere near the percentage of the population as the USA

<comment><USER22> How is it a cause of crime?

<comment><USER23> Several factors.

1\. If you go to prison, innocent or otherwise, you're not getting hired afterward. This leads to desperation, desperation leads to...

2\. In prison, you become socially reliant on criminals to simply get by. This results in cultural transference. Someone getting in trouble for shoplifting learns about the joys of [insert more lucrative criminal activity here]. Combine this with point 1 and you get repeat offenders who become 'hardened' criminals. Basically, they get better at crime, because crime involves skills just like everything else in life.

3\. Poor prison conditions result in psychological trauma. This, in turn, leads to anti-social behavior.

In short, we pay a lot of money to create better criminals who are highly motivated to commit more crimes.

</comment></comment></comment></comment><comment><USER24> Sounds like hell, the way he describes it.

However, if you'd take those hellish elements away & ensure silence, I think long solitary confinement might work if you teach people how to meditate. That's just not being done enough in prisons right now. See "Doing Time, Doing Vipassana" [https://www.youtube.com/watch?v=WkxSyv5R1sg](https://www.youtube.com/watch?v=WkxSyv5R1sg)

EDIT: I know this is probably a controversial opinion to non-meditators, but if you're going to downvote, at least provide an argument for why you don't agree.

<comment><USER25> >I know this is probably a controversial opinion to non-meditators, but if you're going to downvote, at least provide an argument for why you don't agree.

I'm guessing it's the pretense that you can simply teach anyone to meditate whether or not they want to learn. Also, it suggests a system where a form of torture is potentially justified because you shift responsibility to the person being tortured. "They took the class on meditation and signed on the line that they understand how to endure solitary, so their suffering is their own fault!"

<comment><USER26> > I'm guessing it's the pretense that you can simply teach anyone to meditate > whether or not they want to learn

Meditation _techniques_ aren't hard to learn, they're comparable to any form of exercise. The hard bit is in doing them _sincerely_ , just like any form of exercise.

Can you teach someone press-ups? Then you can teach them meditation. You just can't make them do it, or effectively.

As to signing up for solitary for an extended period, I wish I could, but _only if it was humane_ (e.g. no violence, feces flung at me etc), which I'm willing to bet (and the article seems to back up my suspicion) _prison_ solitary isn't.

<comment><USER27> What you're describing is __forcing __people to meditate.

The way I understand what you describe: "We will torture you, you can either have it better by doing this meditation thing _we teach you_ or you can suffer"

The issue here is the torture itself, not the fact that the torture is difficult to deal with.

<comment><USER26> > What you're describing is forcing people to meditate.

In no way have I done that.

Addendum: If I describe that a _technique_ is easy to teach or simple to learn, why does that imply _forcing_ someone to do it?

What a bizarre inference to take.

</comment></comment></comment></comment></comment><comment><USER28> I wonder what the physiological effects on the body are from years of no sunlight, no physical exertion, and constant stress? Must have atrophied like crazy.

</comment><comment><USER29> It's another time someone mentions the Plato's Cave. The reason this allegory often makes deep impression is that Plato was initiated, not just a philosopher, and thus actually knew what he was talking about and that allegory is a carefully worded model of reality, as accurate as it could be told at that time.

<comment><USER30> I'm aware of Plato's cave, however, I don't get your reference to him being initiated. Could you go a bit deeper?

</comment></comment><comment><USER31> Torture. It should be abolished.

</comment><comment><USER32> Post right in time for quarantine.

</comment><comment><USER33> TL;DR: It's torture.</comment>


How do I prevent accidental rm -rf /*? - <AUTHOR> http://serverfault.com/questions/337082/how-do-i-prevent-accidental-rm-rf <comment><USER2> First of all, the whole point of the "-f" option is to disable confirmation, which _really_ means "I know exactly what I'm doing". The easiest fix is to stop using that option all the damned time.

When you have strong permissions (e.g. running as "root"), _you should never use patterns in destructive commands, period_.

At best, you should perform a nondestructive pattern command such as a "find" and generate a precise list of target files that can be audited. For example, here is one way to produce a script of commands that deletes an exact list of matching files:

        find * | awk '{print "rm \047"$0"\047"}' > delete.sh && chmod +x delete.sh

<comment><USER3> Better yet: don't remove things. Move them to a folder. My rm is aliased to a 'mv to a trahs folder' function. I have aliased rrm for real rm.

Guis know this, but somehow this piece of UX is forgotten on command line tools.

<comment><USER4> Note that 'sudo rm' doesn't care about your aliases. It would be safer to replace the binary.

</comment></comment></comment><comment><USER5> An amusing and helpful trick that I learned was to keep a file named "-i" in the directories that you want to protect. Glob style pattern matching picks it up and the program rm interprets it as the "-i" flag. It is of course not quite _fool_ proof as it can be subverted, but it has saved the day on occasions, particularly one of my friend's. I had a friend who, for totally incomprehensible reasons, would name his files with * __s and "."s only and then try to delete one of them with predictable and undesired results.

Well, I have done stupid things myself, for example typing "rm -rf / some_dir" instead of "rm -rf /some_dir". I noticed because it was taking a wee bit too long. It is always good to do an ls with the intended pattern first, to check what all files and directories are being matched before invoking rm with the same pattern.

<comment><USER6> One thing that you can do is ls what you want to delete and then do a ^ls^rm -rf to replace ls with rm -rf in the last command if satisfied.

you can even do a ls -rf ./somedirectory and then just do ^ls^rm at least you can in bash on os x.

</comment></comment><comment><USER7> In the other thread someone mentions using a file named -i. A better approach is to use a file named -X, which is an invalid flag for virtually every file- oriented command. They'll bail out complaining an invalid option has been supplied.

On company I contracted for had something clever going on. Not only did they litter -X files everywhere, attempting to remove one (rm -- -X) would result in an access violation of some kind and your session would be killed as a result, preventing a recursive rm from continuing.

People alias -i and forever supply -f. That doesn't do any good at all. The real answer is to be more careful. It eventually becomes habitual. In about 15 years I have lost data to rm twice: the one time I mistakenly removed the wrong folder, and once when I thought I had a copy of the data.

<comment><USER8> Because of the inherent dangers in -f, I rarely use it...with one major exception. Whenever I am trying to delete a directory with a git repository in it, the fact that a lot of the things in the .git directory are write- protected means that I have to either punch Y for what is likely dozens of files, or use -f (or some other incredibly ridiculous and equally dangerous thing like "yes | rm").

<comment><USER7> Same here, my #1 reason for supplying -f is also to kill a git repo.

</comment></comment></comment><comment><USER9> One: don't do anything as root. Root is the system's account, not your user account. If you need to run a service or application, make a new user for that! I've never needed root for anything other than system administration tasks, like apt-get or adding a user. Also, don't run multiple applications as the same user. If you have a web server, a blog, and a forum, you need three users. The web servers can talk to the backend servers via UNIX sockets or TCP.

Two: don't pass -f. Do you even know what -f does, or are you just cargo- culting it? If you need -f, rm will tell you. Don't use it until then.

</comment><comment><USER10> Technically doesn't prevent rm -rf /* itself, but still goes long way to prevent a disaster: use a snapshotting filesystem, like NILFS2 <http://en.wikipedia.org/wiki/NILFS>

Some solutions here center on avoiding issuing rm -rf /* interactively... that's not enough! A broken script or unexpected variable expansion can wreak just as much havoc.

For example rm -rf $SOMEDIR/* :

\- if $SOMEDIR is empty, or

\- (if you suffer from bash) if $SOMEDIR contains trailing space so it will be expanded into separate words: SOMEDIR='foo '; rm -rf $SOMEDIR/* => rm -rf foo /* (which means, `remove ./foo and remove /* ')

An alias won't help if full path to command is specified; that is quite common for start-up scripts.

I have experienced consequences of rm -rf /* once or twice. Now I pause for a moment every time I am about to remove something and double-check the command. Sometimes even prepend `echo' for a dry run ;-)

Edit:

another nasty case of unintended deletion I had was due to a dumb Makefile rule:

      $(CC) -o $(OUTFILE) $(INFILE)

for some reason $(OUTFILE) ended up empty, so outupt went to $(INFILE) -- a C source file -- effectively removing its content. How would I guard against that kind of data loss? A snapshotting filesystem...

</comment><comment><USER11> I'm sure many of us know the feeling of dread that creeps over you when you suddenly realize an rm command you've dispatched is taking longer to complete than one would expect based on the contents of the directory you _think_ you're deleting...

There should be a name for that.

<comment><USER12> The _onosecond_ :

<http://www.unwords.com/unword/onosecond.html>

<comment><USER13> Thankfully, Gmail allows a grace period to allow you to cancel the sent message.

Not that I have had to use it.

I am also very happy with myself for putting my most important files in Dropbox, so it is semi-idiotproof.

</comment></comment></comment><comment><USER14> How about replacing rm with something like <https://github.com/andreafrancia/trash-cli> ? If you only purge the trash when it's necessary and not automatically after every rm, you'd save yourself.

</comment><comment><USER15> Why not type * instead of ./* in the first place? Sidestep the whole issue by eliminating redundant information.

</comment><comment><USER16> Just use tab completion to be sure you're getting what you asked for

</comment><comment><USER17> Some of the answers above seem to involve 'babysitting' measures that almost certainly won't be on the next box you use.

appropriate countermeasures imho:

1\. run an account with the right amount of access.

2\. don't use sudo. (su + password makes you think a bit more)

3\. this sounds dickish, but I mean it constructively. Pay attention. the -f flag means something...

4\. when all else fails, rsync'd folders are a beautiful thing :)

</comment><comment><USER18> Type rm -rf /* in your terminal emulator, place your finger over the Enter key and feel the temptation:

 _"We stand upon the brink of a precipice. We peer into the abyss—we grow sick and dizzy. Our first impulse is to shrink away from the danger. Unaccountably we remain... it is but a thought, although a fearful one, and one which chills the very marrow of our bones with the fierceness of the delight of its horror. It is merely the idea of what would be our sensations during the sweeping precipitancy of a fall from such a height... for this very cause do we now the most vividly desire it."_

Edgar Allan Poe - The Imp of the Perverse

</comment><comment><USER19> I personally go with a two prong strategy:

1\. Backups 2\. Sudo

I rarely do anything as root. If I am switching to root I already know what command I want to run. Backups are for when I do something stupid.

</comment><comment><USER20> If I'm going to be doing something major to a lot of files, I often write a script that outputs the commands to execute, so I can verify what's going to be done. Then I reexecute and pipe to bash.

It's not quite applicable to something used as off-handedly as rm, though it could be done. Something like:

        make-rm -rf /*

might produce output like:

        rm /usr/bin/a
        rm /usr/bin/b
        # ...
        rmdir /usr/bin
        rm /usr/lib/a
        #...

And so on. That can then be piped to bash as a confirmation.

</comment><comment><USER21> Seems kind of strange to be trying to run:

      rm -rf ./*

instead of just:

      rm -rf *

Is there a difference between the two that I'm not aware of?

<comment><USER22> If any files begin with '-', the second version will just expand to '-filename' which rm will try to process as an option (possibly failing or creating undesired results). Using

      ./*

expands to

      ./-filename

which won't be picked up by option processing. Note: You can also do

      rm -rf -- *

to prevent option processing after the '--'.

edit: added a bunch of breaks to prevent the * from being converted to italics.

</comment></comment><comment><USER23> Create a version of rm that detects if you try to delete the root filesystem, deny it, and makes you put a --really-delete-filesystem-root flag to do so.

<comment><USER24> It does seem like this would be appropriate. All *nix systems share the desire to not accidentally rm -rf /, and it should be easy to check for inside rm.

<comment><USER25> There's already a flag to preserve /, but that won't help you with /*.

<comment><USER23> a flag you have to type all the time, or a default that you have to flag out? You can write code to detect /* too.

<comment><USER25> It might be default in some distros but there is no reason not to put it in an alias. The point is that it's already there and you don't have to modify your rm binary.

And how can you detect /* if the shell expands it?

</comment></comment></comment></comment></comment><comment><USER26> Needing the effects of "rm -r /<something>/* " is _rare_. Just cd first.

I think I rarely use rm -r with an absolute path. And tab completion does something similar (list your targets) if you don't jump the gun with <enter>.

PS I'm entirely comfortable with my Alt-B as "rxvt -e 'sudo zsh'".

</comment><comment><USER27> My habit is to use 'ls' to confirm what I'm deleting, then pressing up and replacing 'ls' with 'rm'.

</comment><comment><USER28> I follow the process of file list validation, as mentioned (by me) at [http://serverfault.com/questions/337082/how-do-i-prevent- acc...](http://serverfault.com/questions/337082/how-do-i-prevent-accidental- rm-rf/337395#337395)

</comment><comment><USER29> I don't have an account on StackExchange but the best way to avoid this is to always run find and then pipe to rm.

find . -name " _whatevs_ "

hit enter, verify you are deleting what you expect then hit the up arrow and type:

| xargs rm -rf

<comment><USER30> ...or just use `-delete`:

       find . -iname "whatever" -delete

Otherwise you're screwed if someone managed to put a file named "/" somewhere in your find directory, which `-delete` has safe-guard for.

</comment></comment><comment><USER31> Always type the full path, there's various key combinations to pull this into your command line. Also, you should be using the 'find' command to list (which you check), then delete files. In short, take your time.

</comment><comment><USER32> I used to run: rm /somedir -rf

If I would have hit Return to soon it would have bailed out automatically.

Worked well on Redhat Linux, unfortunately it doesn't work on my Mac these days...

</comment><comment><USER33> I don't remember if it's something I had to explicitly turn on, but zsh gives me a "sure you want to delete all files in ... [yn]?" prompt when I do any form of "rm *", even if I include -f

</comment><comment><USER34> Prefix your destructive commands with echo. Variant: for find, run it once with -print, then once it looks okay replace with -delete .

</comment><comment><USER35> When deleting directories I type their full paths

</comment><comment><USER36> alias it to ask "really? (y/n)" perhaps.

<comment><USER37> This is a dangerous but common crutch. The reason it's dangerous is people get used to it, and then when they go to a system where it's not there, pain and anguish (or hilarity, depending on your point of view) ensue.

<comment><USER38> Maybe people wouldn't get so used to it if it's only activated for rm -rf / (and perhaps /* and variants).

<comment><USER39> Better yet, just use an OS that doesn't come with a self-destruct button: <http://en.wikipedia.org/wiki/Rm_(Unix)#Protection_of_.2F>

</comment></comment></comment></comment><comment><USER40> Don't be root until you need to.</comment>


Lest CodePlex perplex - <AUTHOR> http://www.fsf.org/blogs/rms/microsoft-codeplex-foundation

<comment><USER2> To boil it down to a sentence, "If the CodePlex Foundation wishes to be a real contributor to the free software community, it must not aim at free add-ons to non-free packages."</comment>