skysight-inc/HackerNews huggingface dataset:
Well, I have to agree with the general point here, but it's buried inside a mass of wandering prose, and I'm not even sure the author quite gets it.

Here is (IMHO) the point: assert is for checking invariants.

That said, I doubt that a post like this is a good place to teach people what invariants are. Those who don't know should go learn. To some small extent, that might include the author, as, for example, pre- and post-conditions are not some special contract-thing that is separate from invariants; they are special kinds of invariants. (So, yes, use assert to check contracts; that's part of checking invariants)

And:

> You wouldn't write code like this:

if not isinstance(x, int):
raise AssertionError("not an int")

Sure I would, if x being an instance of int is an invariant of my code. But if it isn't, then I wouldn't.

I also accept that, as the author says, "assert" has its quick-and-dirty uses. Putting an "assert False" around an unwritten portion of code is a reasonable thing to do, particularly if it is code that one expects to be used often, as the "assert" will continually complain of its own existence as long as it is there.
"Within the Internet, an Autonomous System (AS) is a collection of connected Internet Protocol (IP) routing prefixes under the control of one or more network operators that presents a common, clearly defined routing policy to the Internet", from http://en.wikipedia.org/wiki/Autonomous_System_Number
Ive been using perforce/p4 since 97. the last 8 years have been coupled with P4V and the eclipse plugins. My workflow is virtually identical to the much offered Git branching model [0]. Turn it -90deg with time left to right. Rename "develop" to "trunk". and think of "master" as being the release labels.
release and feature branches are created from the build label of the previous release needing special changes that can not just go into trunk or when we want to do a minimal patch-only release.
a developer makes local copy of the portions of the trunk they want/need.
the server knows who has what opened for edit/add which makes checkins fast. only the change must go in.
same for regular update of my local workspace.
we rarely have people editing the same exact file and if we do its a simple resolve in P4V during your commit or integrate activity.

So far, there are FEW benefits i see to using, or switching to, GIT:
LOCAL REPOSITORY - I have the whole repo for what i am working on so can work remote easier
LOCAL VERSIONING - I can create lightweight local branches that duplicate only what is required without resync of my local repo
POPULARITY - all the cook kids are using it so lots of ops utilities now are built expecting it to be there under the covers.

I can live without the LOCAL benefits. I have for 8 years.
I worry about the third - popularity vs. merit.

Where are the concrete comparisons showing all the features and functions of these solutions side by side and how they compare for a student, startup, or enterprise?

EDIT: found a newer perforce:git comparison on the perforce site[1]. The LOCAL REPO/VERSIONING is available with P4SANDBOXING.

I suppose modding me down is appropriate since i picked up on the POPULARITY aspect of the discussion and don't have any Hg experience. However, it seems these discussions just keep happening and there is no one-true-solution or approach. they each have merits and faults. it will be the careful consideration of these that leads to your own solution implementation. The popularity of GIT appears to be its strongest argument.

EDIT2: located a GIT-v-Perforce on SO.[2]

so many of the diffs, however, have been met with sandboxing

It really appears the strength is in popularity - everyone else uses GIT so you should too…

[0]: http://nvie.com/posts/a-successful-git-branching-model/
[1]: http://www.perforce.com/sites/default/files/pdf/perforce-git...
[2]: http://stackoverflow.com/questions/222782/git-vs-perforce-tw...
I really wish people would shut up about Google's "ideals". They're a company, not a messiah. Companies operate on a midpoint between what they want to do and what they need to do, and Google (like every company) has slid towards their "evil" neccessities over time.

Don't like it? That's fine, neither do I. But stop preaching about a morality that was never there.
If you still had access today, it would be a perfect platform for Bitcoin mining.
I usually use 'password' or 'pa55w0rd' :)
Of course there are exceptions: some people like to link in openssl libraries statically; that removes another attack vector - like swapping an openssl shared library with something that returns a constants for all random numbers;

On the other hand that is also a bit silly; if the box is owned then all else is peanuts;
I'll try to remember to reply here when I get it working.
Scott, you seem to have a surprisingly good handle on a fundamental problem with our healthcare system. Let's catch up offline :-).

- Your old co-worker
After reading the Steve Jobs book, the biggest emphasis was focus on making a great product. He was never in it for the money; He was making $1 a year at one point.
Do you have any reliable references for this use of Naloxone as a "lunch hour fix-ender"? I'm led to believe the administration of it isn't particularly pleasant under any circumstances, and the risk of an excessive dose causing precipitated withdrawal symptoms is probably the worst.

Not to mention, the mere idea that you'd waste money by ending it early would send many users away laughing.

And if you have the money and time/connections to be sourcing Naloxone on a regular basis, why not just use a short-acting opioid like Fentanyl (or even just Heroin?)

In what ways would the 3-martini-equiv benzo + nominal antidote be worse than, say, 3 martini lunch? It seems like the problem is more with irresponsible people consuming drugs for recreation when they shouldn't, rather than the drugs themselves[1].

Giving such irresponsible people the ability to hide either consumption without totally reversing its effects would indeed be a net negative, but same can be argued of breath mints or dark glasses, neither of which are known to make you a better drunk-driver.

Overall, I'd be deeply surprised if there wasn't something objectively better than alcohol in every way, but agreed that it's going to take society a long time and a good number of missteps to accept and adapt to it.

[1] Ignoring for brevity the issues of dependence, addiction and tolerance that might require them to dose regularly, or risk even greater impairment or harm to themselves.
Really i'm just here for the hardware and debugging stories.
NFC is clearly not the future.

Square/PayPal (also not the future with their current products) are not incompatible wit Coin. In fact, Coin fits well into the current ecosystem.
At the risk of sounding like another one of the "Google is evil" people, I'd like to voice my concern that Google is better at managing mail then I am.

I just moved from one country to another and I can't change the billing settings on my Google Apps account because... Google Apps don't support that. The official stance is that I should just download a backup of my accounts, delete them, recreate them with different billing options. However, other than preserving my mail and Google Drive, this won't preserve any of my other content which must either be backed up using third party tools and then manually recovered/recreated.

I'm not sure how this can be interpreted as a sign that Google can do this better than I can.
Amazon's Secret Formula Could Keep It From Ruling the World
> To my knowledge, reflog won't help you get back uncommitted work that you nuked with git-reset --hard.

Every version control system has a way to overwrite a dirty (modified) work directory, so git is hardly any more dangerous than any other tool.

It also won't help you get back uncommitted files that you destroy with `rm`. No other tool does, either.
MTV Artists
I'm 52. There was plenty of earlier stuff, but the oldest code I can still find online is from an article I wrote in 1992 on how to write assembly language routines to extend the QBasic interpreter.

http://www.petesqbsite.com/sections/tutorials/zines/qbnews/1...
Try http://www.dailyrotation.com The top 100 headlines turn up interesting articles for many areas of interest.
I find this really disturbing:

http://ipinfo.io/recent

Might not want to display people's data like that.
I have my TV as second monitor to my PC in the living room. It's great.
He's right. Decimal 5 is binary 101, hence 3 bits.

I wasn't literally referring to data bit, though. But he has a point.
Another post in the do this, do that, because it's better for you fashion. Since when people are going to stop writing with so much entitlement ? What do they know what works for me anyway ?
What's the rest of the story, since the funding went well (how did they fail)?
As much as the NSA concerns me, and as a political issue it's far more important, I am interested in reducing dependency on Google because as far as I am concerned Google has broken its trust with me all by itself. It has nothing to do with the NSA debacle.

I don't have time for a rant but the short is: I'm sick of their identity management, their willingness to put blatantly obvious "search bubble" results based on recent (or even non-recent) activity-- stuff that is prominently visible to anyone who might be sharing a screen with me. Ditto for chrome's "most visited pages" thumbnails when you open a new tab, which I disabled but had to install a plugin to do. There's some other minor issues. But the final straw came a few weeks ago when my search history showed up unexpectedly on my girlfriend's phone-- I suppose because she logged into chrome on my laptop to check her Gmail. Until she logged out, auto-complete on her phone was using MY search history from chrome on my desktop. What the FUCK? Obviously I trust her enough to let her log into my laptop so it didn't cause me problems here, but I had no way to know that would happen. So what's it going to be next time? What's google's next clever/reckless silicon valley echo chamber idea that's going to cause me problems?

I'd rather not wait to find out. So I've begun the process of reducing google dependence. Email is a big one, Gmail is my single biggest google dependency.
You are very lucky that the hacker didnt' take precautionary steps to edit scripts/hide their activities.
What You Don’t Know About Pie Might Just Kill Your Business
I disagree, It seems women get more rape threats than men, hence privacy would have a higher concern for them. As I've never had a rape threat directed at me, I'm far more relaxed about my privacy than I can imagine someone who has had a rape threat directed at them would be.
My point is that git-reset --hard can remove data from the working tree filesystem that never hit the DAG in the first place:

$ git init
Initialized empty Git repository in /home/john/tmp2/.git/
$ echo "foo" > foo
$ git add foo
$ git commit -m 'init'
[master (root-commit) 84fb5d1] init
...
$ echo "bar" >>foo
$ cat foo
foo
bar
$ git reset --hard HEAD
HEAD is now at 84fb5d1 init
$ git reflog
84fb5d1 HEAD@{0}: commit (initial): init
$ git status
# On branch master
nothing to commit (working directory clean)
I'm 40. It was rewritten into another language but I wrote the original bra search on victorias secret. I don't remeber the language it was some IBM product but i didn't even have a looping statement you could only loop through data.

http://www.victoriassecret.com/bras/shop-by-size
What do you mean by "people's" data? It's information about an IP address that is completely public. You could find it by going to ipinfo.io/<any random IP address>, or by using various tools or other websites to look it up.
When the password consists of 4 characters, each being 0-9, there are 10,000 possible passwords; 14 bits are required to represent 10,000 possible combinations of anything:

log(10000) / log(2) == 13.28771

With 5 characters, each 0-9, there are 100,000 possible combinations, and that requires 17 bits:

log(100000) / log(2) == 16.60964

Therefore, 12345 offers 3 extra bits of security compared to 1234.
Well, they sure want Facebook likes, they are offering $20 off if I "LIKE" them.

Personally though, I'm not really interested in any company that is going to charge me a $20 penalty for not joining Facebook and "like"-ing them.
A simple, principled way of solving October's problem is to model it as a Markov chain with absorbing states (the "Finish" square, and the two invisible squares past it -- the two invisible squares are unnecessary as mentioned by jtsummers below), and compute the expected absorption time starting from the first square.

See e.g. http://en.wikipedia.org/wiki/Absorbing_Markov_chain
http://www.zdnet.com/icache-geodes-spectacular-crash-and-bur...

tl;dr: Quality(?) issues; then iPhone 5 with Passbook, new form factor, and lightning connector.
XMPP Syndication, (And with that interoperability), an increase of invasiveness of their ads (for those without adblock), the death of Google Reader, there's plenty more if you read up.
This is one of the few technical communities online where I post comments. The problem I have with reddit is that downvoting is too rampant. I also enjoy the focus here on startup companies, even though I'm not a founder. reddit seems to have this bias against startups which is overly cynical and even demoralizing. To me, the startup scene is (part of) what makes the software industry interesting and distinguishes it from, say, chemical engineering. If I ever do decide to become a founder, the information I've picked up here, almost by osmosis, will undoubtedly be invaluable.

Regarding posts about new languages or frameworks, I really don't think anybody is seriously suggesting you go rewrite your production codebase. That's silly hyperbole. Lots of people here actively work on side projects or they may be in the planning phase for a new startup with no code written yet--situations where they can legitimately consider using a newer framework or language.
To be clear, I think that the behaviour of git-reset --hard is absolutely appropriate. I am just correcting the overly strong statement: "No matter if you rebase, reset --hard, or any other "destructive" operation, you can always get back to your prior state with nothing but a quick look in the reflog."

There are situations that reflog won't get you back from, but those situations are perfectly logical and appropriate exceptions.
Show/ What do you think of this prototype? (Online Window Shopping)
SourceTree is good if you can handle the .NET 4.5 requirement. At work, we can't risk the breakage 4.5 can possibly do to 4.0 apps and can't force customers to upgrade for 2/x applications so I don't bother.

My first foray into DVCS was Mercurial through Kiln and subsequently TortoiseHg. It's always been great but the introduction of the workbench made everything gel. Having all of the UI in one spot made the experience that much easier. It makes discovery pretty simple compared to TortoiseGit/SVN where you have to know what each menu item maps to.

I've since moved to GIT for work and personal use. GIT flow sold me as hg flow really didn't feel equivalent. I also like submodules as they make proper segregation that much easier. Hg has patch queues which made working on items that weren't commit ready easy. At the time, I didn't understand feature branches so I should likely revisit Hg earnestly. Hg has always had a better user experience where error messages aren't cryptic but there's a wealth of knowledge online to solve any problem in either DVCS at this point. There's some spots in git where you still need the command line where TortoiseHg seemed to cover every need I had.

TFS finally supporting git as a repository, despite its caveats (convert once, only vs2012+) will likely push git pretty far. Having used Ankh, I was never impressed. I'd rather use tortoise + git source control plugin or git extensions as the experience is definitely sufficient. I actually prefer the tortoise workflow over doing it all in vs though but there's a bulk of what we do outside of vs anyway so being proficient there helps tremendously.
It's a solution that does work, but it seems to me like a last resort and also a solution that doesn't scale very well. 35.9% of the US population over age 20 is obese[1].

1. http://www.cdc.gov/nchs/fastats/overwt.htm
DigitalOcean One-Click WordPress Install
Thanks for the Pycoders Weekly mention John!
Yes. I just promised myself yesterday to stop writing bash scripts for things other than setting up an environment and launching another program. What pushed me over the edge is most of the script was incorporating the kind of fixes from the article (force variable to be treated as int, add dollars signs to access as variable, and so on).
I, for one, think this is awesome. They even have one-click installs for Ghost.
Note the tags on the story: "Business, Parody, Tech"
Flip it on its head and HN comments are one of the best places for me to learn, find interesting things to read, and above all read about perspectives and experiences on a subject different from my own.
I think the parent is talking about Bret Victor.
I think this gets to one of the issues people who have previous source control experience have with git. They apply the concepts from, say, subversion to git, and then have trouble.

Take branches for example. In subversion, branches were heavyweight, scary things. In git, they are extremely lightweight, in that they are really nothing more than a pointer to a specific commit. They almost shouldn't even share the same name, they are so different.

Basically, I found that I got much better once I stopped trying to apply my old understanding of subversion to git, and especially once I just started playing around with git commands on a dummy repo, to fully understand what was going on. Now that I've done that, I would never switch back to subversion. Perforce, maybe, but only for certain very specific scenarios.
$1 a year and a massive pile of stock. That's a big show of faith in your abilities and your company, but that's hardly "Never in it for the money".
It's a pity they're a subscription and also they want me to log in to view the pricing.

Edit: There is a once-off price and also somewhere to apply if you're working on open source.
Quick and simple solution. If you are only using key based logins then just disable password SSH logins, add:

ChallengeResponseAuthentication no
PasswordAuthentication no
UsePAM no

To your sshd config and then you don't need to worry as much about if one of your accounts has a password of 1234.
Have you tested 4.5? What breaks?
This. "Why R" is because context matters when picking a programming language. Python might have libraries to work on the models I need. R will have them, unless they're really, really obscure.
"Perforce, maybe, but only for certain very specific scenarios."

These days you can get a lot done using git as your perforce client but.... ick.
Developing a Fax Machine to Copy Life on Mars
That's an interesting point. Here are my off-the-top-of-my-head thoughts:

I guess the real goal is proper separation of responsibilities. When I cook a meal, I use devices that run on electricity. I want to be able to power them up by plugging them in without thinking much about it. The people who work at my power company need to think about the intricacies of generating and transmitting electricity, but I don't want to. On the other end, the people who eat the food I cook should not have to worry about the use of a stove timer or a rice cooker.

Similarly, when I put together a software package, I am functioning as a programmer/software designer. I am interested in the code, how it is structured, and what it is supposed to do. Time spent worrying about storage & version management is generally time spent away from my primary task. Someone needs to worry about that, but, for the most part, I don't think it should be me.

The users of the package I write just want to use it. They care that it does what they want. The fact that it is written in Python, developed using agile methods, etc. are irrelevant to them. (But not to me, as a programmer.)

And maybe for the users, the software is a tool to help them in their business. The customers of that business probably should not care about the software at all; they just want whatever service the business provides.
Having seen how this occasionally works out, I don't.
I'm not sure about shelve, but histedit, rebase, and mq are all history modifying extensions. Mercurial differs from git in that it prefers immutable history.

The extensions are there if you really need them, not as something you should always setup imo.
Dr. Dobbs Must-Have Books for JavaScript
Disney Struggles to Make Its Free Gaming Apps Pay
Noam Chomsky: Fake Linguist
Security researcher Cédric 'Sid' Blancher dead at 37
Tornadoes kill 3 in Midwestern United States
> git is dangerous out of the box - it can destroy your work very easily

I really wonder what do you mean by that?

Yes, it's relatively easy to checkout some older commit and end up in a headless state, where an ordinary `git log` command won't show your more recent commits. And then panic and think that git has destroyed your work. But all your commits are still there. You need some more involved way (like the reflog) to get back to them, but git has not destroyed them.

After 30 days or so, git may run garbage collection and remove dangling commits, thus really destroying your work then. But your words "can destroy your work very easily" are a bit strong if this is what you mean?
yeah, that's not why, but good enough I guess.
Google Java Web Developer job posting from 2000
How did a wall of text get to the first page? Some ones managed to create a HN bot.
Oh wow that is a really cool concept.

My only little concern is that it would work better as an ad network - I think people would rather just look at companies' websites to find the information, than going to your website. That would mean exploring adding this to monetize other peoples' maps.
I am surprised no one has mentioned Loop yet, it is a step in the right direction regarding Mobile Wallets: kickstarter.com/projects/loop/pay-with-loop
If you are Dwayne or Abdulaziz at

http://www.quora.com/Web-Crawling/Is-it-possible-to-build-a-...

I want to thank you.
Heh, I also destroyed my Linux system at about that age. "swapon /dev/hda". Oops.
Articles like this make me wonder if I'm stupid. 95% of the time all I ever do is commit my work and push/pull, whether I'm using svn, git, or hg. I just hardly ever find myself needing to understand anything more complicated than that. Why does it seem like everyone else has spent thousands of hours understanding esoteric git or hg incantations that I've never encountered the need for.
What are your greatest concerns by offering this option?
On Google, I hope you have read this:
http://www.businessinsider.com/sex-and-politics-at-google-it...
This is hilarious.

What is so illegal about these questions?

Oh, I forgot, I work for NSA/CIA/FBI/.....

Beware.
Yes, the tax is the VAT, which is designed to be only paid by customers. It's roughly analogous to a sales tax in the US
Google Targeting Online Businesses Worldwide To Increase Google Adwords Profits
"-Weverything" if the code is compiling perfectly, but you're just bored. If you're not a complete masochist try turning off some of the sillier ones (-Wno-padded -Wno-unused-parameter -Wno-conversion)
Ok, yes, I agree with that clarification (and I missed that you specified in your original comment "uncommitted work", my mistake).

If you git reset --hard and you have a dirty working directory, you can absolutely blow work away. That's one of the main reasons to use git reset --hard, but I agree that it needs to be used with intention.

The easiest way to protect against it is to never use it if you have a dirty working directory, always commit first and then reset --hard after you've committed.