skysight-inc/HackerNews huggingface dataset:
I dislike exceptions, because they are magic. You can't tell what exceptions the piece of code you're calling will throw. It can also easily change with a library upgrade.

I like exceptions, because they are magic. While prototyping or for small utilities it's perfectly OK to "crash" on any error - nice error message can help then.

However I prefer when the final version handles all errors explicitly. I want to see it documented in code that error handling was not forgotten and it was deliberate to push certain errors back the stack. Of course it can work with documentation telling that this library never catches any errors, but it will put the burden on me. I also prefer to have a code, because documentation, more often then not, is lying.

Having written all that, I'm wondering how exceptions work with Python's "Explicit is better than implicit". I guess in case of exceptions this rule has lower priority than some other rule that priorities simple looking code. That would align with my use of Python - strictly for one off utils and prototypes.
Any visitor, of course. Sounds like you know who that visitor is.

The island is Little St. James.
Unconfirmed and probably untrue :/
"To solve the problem of soul-destroying traffic, roads must go 3D"

This is not very convincing. Solving congestion by building more roads isn't exactly a new idea. Its track record isn't that glorious either: https://en.wikipedia.org/wiki/Induced_demand

Not to sound too negative but how about some evidence on why it will work this time?
Huh? You could easily live a comfortable life on $55k a year in say Tacoma, WA or Eugene, OR with a wife and a kid. I've earned less than $45k a year living on my own in Seattle not even 5 years ago, and despite shopping at expensive stores, eating out daily, and spending quite a bit on other random stuff, I always was able to avoid going into the red financially without watching my spending much at all.

Even in Seattle, I know of married couples who spend under $2k a month total, inclusive of rent, utilities, eating out, buying random stuff, etc while earning north of $120k each. Sure, its a meek lifestyle, but it can be quite fulfilling to know you aren't a consumerist whore.

If money = happiness, you are apt to lead a really sad life!
>But after the fact optimization rarely happens, is more expensive and won't get you there. Don't do unnecessary optimization at the end of the project and don't them them in the beginning either. The necessary ones need to be thought out in advance (choice of right data structure, algorithms, tools)

The worst optimizations I've ever seen are pre-optimizations. I've seen many designs, in fact, that were attempting to prematurely optimize and inadvertently caused future performance problems.

The best optimizations, by contrast were done at the end of a project where the default was "keep the code clean", not "try to predict future performance issues".
I have argued enough in my life to not get angry over some internet news in another country. But, sexist acts like from this organization acutally makes me furious in a way that I have zero understanding for such acts and I now view them as my enemies.

I still stand by everything I wrote, it is a sexist act from a sexist organisation. Until their behavior changes I will forever believe that.
Yes, very condescending, in the same way Neanderthals were seen as primitive cave men until hard evidence showed they were at least as advanced as modern humans in many ways.

Also, this is a completely different species of human. A bit presumptuous interpreting there actions from homo sapiens mindset.

For all we know they could have been Spock like atheists.
I wonder, is there any way to control this behaviour from software? Or via microcode/BIOS update?
GAs are also more relevant to problems that cannot be represented in continuous vector space, i.e. where the problem is symbolic and not real-numbered.
This has been my greatest frustration with slack (and with google voice calls, though I will angrily use Chromium if I have to, which I guess is Google's goal)
It's a lot easier to tunnel through sky than rock.
And Linux support for 5-level is being actively worked on since December, a quick git search shows this in 4.11:

Merge 5-level page table prep from Kirill Shutemov:
"Here's relatively low-risk part of 5-level paging patchset. Merging it
now will make x86 5-level paging enabling in v4.12 easier.
I feel that the "error" handling is one of those "core things" that people have rarely fully understood. Especially newbies starting are often confused and things get muddled. In all honesty it took me +10 years myself to reach some kind of clarity on this. Anyway I find it that when you lack that clarity your code will be quite messy (isn't this always the case?) and things will get muddled. And since error handling is so precarious your implementation quality will suffer considerably.

So below is my take on this with 3 clear labels and guidelines on how to apply. Hope this helps.

There are 3 kinds of "errors".

1. Bugs.

- created by programmer.

- invalid state of the application - >it has transcended it's own logical realm and you can't reason about its behaviour anymore.

- null pointers, OOB, etc.

2. Errors that are "expected" part of the program execution.

- you need to write logic flow to deal with this

- it's expected and quite normal that this might happen

- incorrect (user) input, file not found, socket timed out etc.

- this is really just an error from the end user's perspective.

3. Errors that are "unexpected".

- some very unexpected error

- system resource allocation failed, out of memory, out of file handles etc.

- critical resource was not accessible (for example a "must have" config file was not found)

How to deal with these?

1. Abort and dump core. Yep seriously, just do it. Blow up with a bang and leave a stack trace that you can analyze in the post-mortem debugger and see what went wrong.
As a result your application will be simpler and more straightforward. Simply, don't try to write logic to deal with programmer failures. It will just clutter your program, mask the problem and make fixing it harder.

int divide(int x, int y) {
if (y == 0) {
throw std::string("Divide by zero");
}
return x / y;
}

passing y=0 the function is clearly a bug. It'd be much better to core dump here. Unless the function was designed with double purpose of validating the input and performing the actual function. I'd much rather split these into two different functions, since the core function may be called from different contexts, some of which might not require any input validation at all even. And the validation function clearly should not be using exceptions either since it's quite normal and expected that input from external sources (such as the user) can be malformed and you probably want to write logic that then bashes (sorry.. informs) the user about their wrong input.

2. Use error codes.

3. Use exceptions.
> If America had better trains and subways, it could move massive amounts of people. Train automation is a solved problem, and currently implemented in cities around the world.

In most European cities, if you get off at train station, you're in the midst of (or very close to) the city center, office locations, touristy walking sites and plenty of choices for retail or food.

In the US once you get off at the train station, well, you're at the train station, and now need a car to go anywhere you actually need to go. NYC and SF are likely to be the only exception - train stations as close as LA or San Jose are fairly sparse and have limited connections.

You can run the fastest most frequent train you can handle, and California in fact is building one between Borden and Corcoran, but the "step 2" in US cities generally involves getting a car.
the smaller diameter is because he's building for cars and not roads, and as for trains I think he need the early adopters aka, the rich to invest. mass transit is for the poor and doesn't attract investors. but in the long run it's probably better. but if you look at the mockup video there's an mpv that enters the tunnels, not just teslas.

I think it's move polivalent to transport vehicles (personal or mpv) that way the last 1-5 miles can be resumed by the vehicle and they don't have to stop everywhere (which is the main crutch of trains), you want to cover as much area and not have "why don't you stop near my house" syndrome.

there's also nothing stopping bicycle riders from using the system provided there are seats to strap into and goggles to wear.
I think those labels aren't really helpful when discussing individuals. A lot of people are in pretty much every part of the political spectrum simultaneously.

In fact, I prefer to classify political views differently, by splitting them into two buckets: those who have figured out that every issue needs an actually effective solution, and those who follow their ideologies blindly.
Someone commented on twitter that it's weird how much he empathizes and is complicit with his mom, especially after owning a slave. He also points out that he mentions she worked at Fairview Training Center, which doesn't exactly have a good history -
http://www.oregonlive.com/opinion/index.ssf/2010/01/erasing_...

Usually I feel like pointing out these things is sort of not understanding the perspective, but also after reading Lola's obituary (http://o.seattletimes.nwsource.com/html/localnews/2016807437...) it seems like Alex Tizon resolves himself of a lot of the responsibility for the cruel things his mother has done. Am I missing something here or does this seem to humanize her cruel actions a little bit too much...
Maybe you should stick your nose outside a bit more often? In Poland if you make ~$20k/year you are super rich, can easily afford to not just buy but build a new house. There's absolutely nothing miserable about it. Saying that "nowhere in the world" $55k provides a good life is just hilariously wrong.

Even in UK, I make ~$35k before tax and I'm living a very comfortable life.
The difference is that it takes up existing infrastructure to do that. A freeway/Roadway in itself takes up huge amount of spaces from the city. A tunnel under the city would only take space at the "exit" points.
"Losing all respect" for them has nothing to do with the 100% veracity of their published content. People get so intoxicated by celebrity culture these days...
Ask HN: (Fully) open Android phones?
I'm looking at the Fairphone 2 or the Golden Delicious GTA04 (running Replicant) at the moment. Any other options I am missing?
I used to do a little c++ as a student and never found a way to correctly handle error using exceptions. I am now a scala user, and in scala Either is the canonical way to handle errors. I understood the Either construct quickly and after a year using it, I wouldn't come back to the c++ exception.

Note that in c++, the absence of algebraic data type made it a little bit hard to understand how Either is coded.
there's nothing stopping a specially sized bus from using the system or cyclists (if they adapt it right.)
Can you not break the work into smaller pieces?
Or am I missing something fundamental here?
I don't use a smartphone, and the only smartphone-ish device I have (iPod touch) I only even bought because some things won't even run on PC anymore. This is successfully selling me on getting a high-end android phone, something I never thought I would do. I'm always looking for ways to reduce the amount of space my office setup takes.
To attract potential job offers.

I don't care about the language nor its ecosystem the slightest. If I need a dynamic language I stick to Perl or Chicken Scheme.
The link you provide states that the leak contains no breaking news revelation because email was not the communication canal used for important matter. But despite the absence of such revelation does not mean the leak is void of significant content.

This echoes what other media have reported, that nothing illegal has been found in the financing of the campaign but it shows that it got its money from banking networks and start-ups exposing the link between Macron and banks which has been denied during the campaign[1].

There are a number of other legitimate questions raised by the data found in the leak such as how Macron got access to parti socialiste's budget for the 2012 presidential campaign for example. Link this with the fact that parti socialiste pulled the rug under the feet of its own candidate while parti socialiste's current president Hollande was not a candidate and secretly suported Macron and you get a behind the scene glimpse on this french presidential election.

[1]: http://www.liberation.fr/elections-presidentielle-legislativ... and https://www.mediapart.fr/journal/international/130517/la-pis...
Not seen that one, and I don't really "get it." Granny Smiths, doing their own thing, are quite possibly my favourite eating apple.
That's cute, people thinking we still have privacy online. ISPs will be selling your browsing history soon enough.
The concept behind sin taxes was to tax what you don't like more than what you do like. Modern governments apparently hate jobs and earned income the most.
Same issue in the Uk. Momentum (militant whacko commies) have been trying to claim everyone who is against May and her various ruinous policies should vote for Corbyn and his various ruinous policies.

Fortunately in the UK there's another voice at the table in between the extremes. People tend not to vote for them because of fear, and a misunderstanding of the soft power available in politics.
Me too. I interpreted it as a smile, but just assumed it was some meme I didn't know about (and couldn't be bothered to look up).

At least I never replied to anyone with an explicit J, as in "Thank you J"
Omg, slack is worst shit i ever seen
I'm called James so when I got a "Thanks J", I thought they had taken it on themselves to give me a new nickname. Perhaps signing off my emails with "Thanks :)" gave them sane impression.

Strangely felt better when I realised it was a smiley face.
It's a hackneyed cliche, but the plural of anecdote is not data. I'm saying that the baseline assumption should be one based on a known baseline, which this paper gives. If there's data to support a decision in a more specific case than the broad grab-bag this paper represents, that would be interesting. Otherwise what you're saying amounts to "one should bet on being an outlier" - and if that's the bet, the payoff has to beat the alternative. Everything you've mentioned will be represented in that average.
Yes, smart people are magic. Doesn't matter how much sense the idea itself makes, one only needs to ship it off to those 'motivated talented people', they will figure everything out.
Infogr.am acquired by Prezi
>Seriously, the housekeeper's situation may not be too far off from the archetypal startup employee working 18 hour days and sleeping under his desk. None of us know, and none of us should claim to know.

Do you really believe that some 23 year old fresh out of college programmer working 18 hours days by choice in hopes of either a significant payoff or at least experience that will anyways lead to a very well compensated job is at all similar to a women who is sleeping on a mat in the kitchen of an empty house full of empty rooms who is then woken up every morning by a phone call explicitly designed to be demeaning so that she can start her menial, low payoff, worthless experience work?
MasterCard Serbia asked ladies to share FB photos of their credit card
For what it's worth, as of 16.04 Ubuntu automatically installs security updates:
https://blog.appcanary.com/2016/unattended-upgrades.html

In snapcraft, all updates are automatically installed:
https://docs.ubuntu.com/core/en/reference/automatic-refreshe...
https://www.youtube.com/watch?v=DLxqdf89hRo
Block them on Signal, its easy peasy! Their messages/calls will go to /dev/null while double checkmarking even!
Remove iTunes DRM Protection Using DVDFab 10
CAN YOU TRUST THE TORY GOV +USA ISRAEL AND ISIS
Show HN: Occies – Designer eyewear with screen light protection
Huh? Do XHR requests go on the navigation history stack? WTF? Why? And why would any site use the same URIs for API endpoints and frontend/view navigation places? And in that case should the Content-Type (or Accepts) be the main factor?
If he reduced the tunnels even more by a factor or 20 instead he could put schweebs in the tunnels.

http://shweeb.com/
> - have not managed to create any global brands

Xiaomi is the third largest smartphone manufacturer in the world, and it is quite popular in Europe.
No response...I think these are companies that have GraphQL APIs, but no actual relationship with Graphcool. They shouldn't be listed as customers.
> This is a rather rose-tinted view — old cars (c. >25 years) broke down very frequently (by modern standards)

25 years ago is 1992, this is already way into "modern car" territory and million-kilometer executive cars.
Do you not get Bramley apples over there? Large green cookers that are delightful for apple sauce?
I have no helpful advice, but MAN some people are evil. I can't think of another word for it.
That and Cox's - again not sure if you get them in the states.
71% of App Installs Are Due to Push Messages
True that. But you could replace "Machine Learning System" with "code base" and "linear algebra" with "C++" and it would be an accurate description of most corporate software development I've seen.
Cloud spanner gets me super exited, I wish they would show more details about its design and architecture.
It reads to me more of a Spring Boot issue than a Java issue per se.
If you feel like remembering vim's commands is a chore then it is not for you. For me they are reaction, I don't even think about chaining then together to accomplish my task.

As for plugins I do not see the need for NERDTree or buffer management. At least for me searching (:find for files and :b for buffers) works perfectly fine and I dare say better/faster than file tree navigation.

Multicursor is fun, but it can be achieved with a plugin in vim also, but I'd just make a macro for it.

Moving lines up and down can be easily done with dd and p, so I don't see the issue here either.

>competing GUI text editor

There might be your problem for me using vim with tmux makes my life so much simpler than using gVim or other GUI editors.
The tunnels themselves are very unassuming

I'd wager that there is a lot of hidden infrastructure in a tunnel, which carries cars compared to train tunnels.

Ventilation, as a very critical entity, comes to mind. Also safety features are extremely critical. I live in a country with lots of tunnels and essentially every longer auto tunnel has additional tubes that are under pressure, for example. That's required if you suddenly have a burning vehicle in the middle of a narrow tube.

While car tunnels don't need to be sexy from an optical perspective there's a ton of necessary infrastructure and safety features, which aren't immediately obvious.

Maybe this changes when we all go electric, but I really don't see that happening anytime soon.
I think this is one of Munroe's general digs at corporate culture, and not specifically aimed at machine learning, that's just the current buzzword.
Way to push your agenda on HN.

I personally see Assange as the most important of these three. He started a revolution and enabled all the Snowdens and Mannings to reach the masses.
> I just boggle at the idea of a server with 1TB of RAM.

MooseFS (a scale-out storage system) keeps metadata in RAM for low latency and is known for pushing the limits of commodity hardware in big installations. I presume the same applies to any kind of low-latency database of similar size.
Think about the roads they were driven on - modern cars would suffer tremendously if driven on surfaces like that. You don't get those 100,000 miles on dirt roads full of potholes either.

Also, it was much easier to fix many parts by yourself if you knew your car a bit, but that's a different topic.
Corresponding Analysis
That mealtime happened. This means Podesta enjoys performance art, the propaganda was that this meant he was a satanist paedophile.
Couldn't tell if you are being sarcastic, so excuse me for answering like you're not.

It doesn't match the artistic quality and cultural significance of st sophia or the pyramids, not even close. It's just a big glass and steel office space surrounded by a park. Sure the shape is not common, it's gonna have a few high-tech gimmicks and it carries the whole "apple" aesthetic, but it's rather blunt and feels generic (at least for me). Don't get me wrong, it's still a great project for what it is, just not the kind of project that you can call a monument a couple of centuries later
"Just stir the pile until [the answers] start looking right" is actually a pretty decent description of gradient descent.
Hangouts Meet fixes this. I believe they try to pick a codex per system that is supported in hardware (rather than using VP9 whenever it could).

(I work for G, opinions are my own)
I think the role of AI in eliminating these jobs is overstated compared to the role of Cloud, Dev Ops automation and faster iteration cycles afforded by relatively better abstractions and tools for building software compared to 10-15 years ago.

A lot of these large IT companies relied on long term maintenance contracts for infrastructure and legacy software with unnecessarily large teams on self serving time and material (T&M) models. But these days, even large enterprises have to innovate to stay in the game and their experience with top end Agile consulting firms made them realize that you can do with much fewer people with automation and hiring better. On the other hand, the large IT companies got stuck with their old model and without training and experience on challenging projects, the talent atrophied even while having to eek higher salaries every year due to inflation and talent loss to startups and others.

However, the numbers being reported so far aren't huge compared to the employee sizes of these companies. For e.g. 5% layoff would actually be a reasonable trim on an annual basis. In that sense, the carnage hasn't started yet.
If you've ever spun up a VM rather than unboxing and configuring a physical server, you have the visible proof that you seek. If you've ever used Chef/Puppet/Ansible to configure X number of machines rather than configuring each one by hand, you have the visible proof you seek. And that's before getting in to the recommendations and optimizations that AI/ML can offer... it's just the old fashioned AI/ML, MBA's with a spreadsheet, deciding they don't need all those unboxers/configurers anymore.
Tinymce React Native
We're using tinymce as our WYSIWYG text editor for our web platform and we're building a supporting react native app. What's the best way to apply tinymce in react native? Having trouble finding good solution, or any alternative text editors that wouldn't create too many conflicts with existing content posted through our web platform.
> If you're wrapping a try block around every piece of code that might throw an exception, then you're doing it wrong.

Well then the C++ standard people are doing it wrong, because something as expected-to-fail as converting a string to a number throws an exception.

What am I supposed to do if I want to load a text file containing numbers and print out where it failed? Yep, I have to wrap every string-to-number conversion in a try-catch block.

Or in reality I make a wrapper function that does it. This is why exceptions are stupid - 80% of the time you want the context provided by the program counter in order to handle the error.

int string_to_int(const std::string& s, int def)
{
try
{
size_t pos = 0;
int v = std::stoi(s, &pos);
// Check that the number was parsed from the entire string (stoi ignores trailing garbage).
if (pos == s.size())
return v;
}
catch (std::logic_error&)
{
// This occurs if there is no conversion (e.g. no digits) or the number doesn't fit in an int.
}
return def;
}