skysight-inc/HackerNews huggingface dataset:
[referring to unreachable allocations]

> If you’re writing in C or C++, especially C++ without ubiquitous use of smart pointers to manage memory lifetimes, this is your first guess.

What absolute rubbish. Ever heard of a constructor/destructor (aka RAII)? You can go really far without the usage of any new/delete or a smart pointer, and this probably should be the case all the way up till the OS boundary.
Here's one link, which has 14% of all US prisoners as being drug offenders. Not just marijuana, so that's an upper bound:

https://fivethirtyeight.com/features/releasing-drug-offender...
But the reason we have laws isn't to stop people from breaking them, it's to stop people from doing $BadThing.

Breaking the law isn't itself immoral, it's just one person breaking someone elses rule. Who is to say the law itself wasn't immoral? Certainly the application of the law in this case has been wildly immoral.

There is a data point in "Person X broke a law Y times" but I don't think it's an important one. We all break laws, probably unknowingly.
> Gestures changing every month and becoming increasingly complicated with small variations doing different things, inconsistent experience between iPad and iPhone

Why would the phone's gesture controls change for you every month?
Isn't this exactly what every dating site out there promises to do?
iTunes will show you the space taken by apps, by music, by videos, by documents, and then "other". My other just got slightly bigger all the time. This isn't unique to my phone either.
Could just be biking in an area that has no biking infrastructure (i.e. bike lanes well separated from roads). I commute to work by bike daily and the most dangerous part of that is by far when I leave the cycleways between towns and have to be on the road. Motorists everywhere (except maybe Denmark or the Netherlands) seem to have a very fuck you attitude towards cyclists taking away their road; this shows mainly in disregarding right of way or attempting unsafe overtaking manoeuvres.
Ha wow, I never thought my toy project (salutem) would make the cut!

Glad you like it and I'm open to suggestions for improvements :D
KLT-40S reactor is the same type of PWR used on Taymyr-class icebreakers. So it makes little difference if an icebreaker or a floating nuclear power plant passes through international waters. Also, small naval PWRs like this one are safer than a full scale nuclear powerplant, of which many are scaled up naval power plants.

https://www.economist.com/news/science-and-technology/217260...

https://www.economist.com/node/17647651

http://www.politifact.com/truth-o-meter/statements/2008/jun/...
Benefits, office space, equipment, T&E, employment taxes, etc. This is an old article but it suggests about 2.7x. [1] I agree that it might be less for a startup assuming a frugal startup but it's probably at least 2x salary on average.

[1] http://web.mit.edu/e-club/hadzima/how-much-does-an-employee-... (This is old but nothing really substantial has changed except.)
So does adding a question mark at the end of the title fit your position? It's a title and you did not watch the video, it's the same when you buy that product at whole foods and the label says something, then you turn it over to see it's not medical advice.
Part of HTTP: https://github.com/for-GET/know-your-http-well/blob/master/m...

For a fascinating overview how all of HTTP fits together I also recommend the HTTP decision diagram: https://github.com/for-GET/http-decision-diagram/blob/master...
Facebook Investigating a Claim That an Employee Used His Position to Stalk Women
When I recently added 'click to unsubscribe' functionality to my emails, the URL got wrote out into some logs. Those logs got written to a Slack channel and Slack loves to click any link it sees. Oh, and it doesn't respect robots.txt.

But all I saw was every member of my list clicking 'unsubscribe'. It took a good hour to figure out exactly what was going on.

Idempotence is not the problem here, by the way. That just means calling the method twice has the same effect. But GET should have no side-effect, in an ideal world. Of course, in the case of unsubscribe links, it needs to have a side-effect to comply with the law.
>>especially considering the recent FB Android app revelations about lots and lots of things the phone was doing that nobody realised,

No lots of people realized them, and lots of people have been talking about them for years just no one really payed attention until now.

When you install FB or any other app you get a nice list of things the App is allowed to do, if you do not want the app to do those things you should not install the app.

The problem is most people simply ignore this list and click "install" with out questioning why a Flashlight app would need access to your call history...

With Android the user is in control, Some/Most people can not handle that responsibility.

For a person that is concerned about privacy, Using facebook at all seems counter intuitive...

For me while I do supports Apple's take on user privacy, I do not support their Business Practices of being rabidly anti-repair, anti-ownership, and anti-consumer. It is my device not Apple's, the the fact that Apple wants completely control over a device have I bought from them for about $1,000 is a non-starter for me, I can control my privacy in other ways I do not need my phone OS to do that for me.
One thing that might tip the balance in 2018: there's a growing familiarity and body of open source knowledge now around fpga signal processing among the sdr community.

There are now a lot of well documented open source fpga-based data acquisition boards being sold today at comparatively rock-bottom prices - we just call them sdrs.

The bandwidth requirements for ultrasound would seem to fall easily within the open source state of the art.
A bigger frustration I experience is that some streaming seems to just "give up"; stalling and never resuming. I know the connection and server are okay because I can usually force it to resume manually, e.g. doing a page refresh, so is it just bad server architecture or a codec problem?
When addressing the solution of adding data (salt) I find the authors counter-argument unconvincing:

Don’t get me wrong, this does make it significantly harder
to attack a leaked database to unmask every user, but the
resources required to do so or target specific users are
within the reach of many adversaries.

I don't see how it's more feasible to reverse hash(known_user+salt) than it is to dereference hash(salt), and even state level actors can't do anything but attempt to brute-force hash(salt). IOW without more behind the author's assertion, I don't buy it that adding more data to the data you want to protect is insufficient protection, even against known targets.
At the risk of being overly pedantic/piling on -- this is what bad REST-ful API design looks like in practice.

When you talk to your teammates about the semantics of these verbs and someone just says "oh a GET is fine" and the team agrees but you don't and you can't say it so you don't become "that guy" it's time to find a new engineering org to be a part of.

On the topic of PATCH, check out JSON merge patches (application/merge-patch+json):

https://tools.ietf.org/html/rfc7386
I think it helped on one project for us in a tight looping by 10%. It generally isn't worth it unless you are writing something like a video codec or in our case a cfd algorithm..
> why did the first round of people leave?

most common reason is: because they moved on to a different position. They always left on seemingly amicable terms.
Download, manage and change your favorite wallpapers from the Internet
WallpaperDownloader is free and open source and works with GNOME Shell, Plasma 5, Unity, MATE, XFCE, Cinnamon, Budgie and Pantheon DE. Control the application using the Graphic User Interface or via the icon in the system tray when it is minimized.

Some nice features:

- User can select keywords, download policies and resolution for matching desired wallpapers across six providers.
- User can set favorite wallpapers.
- User can define a path to move all the favorite wallpapers and click a single bottom to do this operation.
- Internationalization.
- It implements an automated changer for changing the wallpaper randomly every X minutes. You can define as many directories as you want.
- System tray icon implemented (for desktop environments which support this feature) with quick actions.

Installation:

Arch Linux.
It is in AUR repository:

yaourt -S wallpaperdownloader

Ubuntu, derivatives and distros with snapd.
It is available in the Ubuntu Software Center via snap package. Just search for it. If you want to install it via terminal, just type:

sudo snap install wallpaperdownloader

Caveats: Snap package fully supports GNOME Shell, Unity, Budgie, Cinnamon, Pantheon and MATE desktop environments. If you are using KDE Plasma 5 or XFCE, then installation via official PPA is recommended.

Ubuntu and derivatives via PPA.
There is an official PPA repository for installing WallpaperDownloader in Ubuntu (16.04 and greater) and derivatives natively. This is the preferred method for enabling all the features of the application and it is recommended for KDE Plasma 5 and XFCE users:

sudo add-apt-repository ppa:eloy-garcia-pca/wallpaperdownloader
sudo apt update
sudo apt install wallpaperdownloader

Additional info:

- My profile: https://egara.github.io/
- Main site: https://bitbucket.org/eloy_garcia_pca/wallpaperdownloader
- Wiki: https://bitbucket.org/eloy_garcia_pca/wallpaperdownloader/wiki/Home
- E-mail: eloy.garcia.pca@gmail.com
I don’t think banks are famous for sharing (or caring :) ).
Ex-Autonomy exec found guilty of fraud in Hewlett-Packard deal
Now I wonder if Safari (& other browsers) has distinct headers for their favorites lookups, to tell these lookups apart from real users and discard these accesses from site analytics..
This is not ingenious in my opinion ... I’ve been at a company for a year that had bought into “Watson” — when I suggested alternatives to the specific apis being used was told in no uncertain terms that they had been consulted and they were going with “Watson” ...

Now a year later I’m finally being asked to clarify “what is Watson” so that the decision makers can better understand the techniques being used rather than the fantasies about what was being used that they were encouraged to develop through misleading marketing and consultants ...
Yes. That implies the average salary is almost certainly <$50K and maybe more like $35-40K.
Y’know, he’s right: that’s technically not a medical claim, it’s a “non-functional” claim. Of course, I also get what you mean; to you and I, that looks exactly like a medical claim! The regulations for all this are slightly mental, which is why things like homeopathy and those bullshit “skinny tea” pyramid schemes survive
Yep. I'd recommend the Mi A1. If you can find one, they're pretty cheap, $200 I paid at a retail store. Great specs, very little trash (Moto X4 is Android One, but ships with Moto specific stuff that is annoying.)
life is too short.
Unfortunately, this doesn't seem to work in Clang because it doesn't support the -traditional-cpp flag. Make sure that you're actually using GCC if you're following along!
I'm surprised the article didn't point out that this applies to C and C++, considering that these are usually thought of as being more efficient than higher-level languages. On Unix-like operating systems (and Windows too I believe), all of a process's data is in a single contiguous block. You can grow or shrink that block by calling the brk() [1] system call, but this allows you to return memory to the operating system only if it's at the end of that block – there's no mechanism to free pages in the middle.

The big problem for these languages is that you can't move objects around in memory because other objects may have pointers to them, and there's not enough metadata at runtime to figure out where those pointers are and fix them up to a new location. This means that if you have an large amount of free memory and have just one little object allocated after it then there's no way, even in principle, to return that free memory to the operating system. In practice I don't think any C allocators even try to return memory to the OS.

There are a couple of mitigating factors to this though:

* If you allocate a huge amount of memory and then free it and don't use much afterwards, eventually the OS will move those unused virtual memory pages to disc in the page file. Your process will still appear to be using a lot of memory, but in practical terms the system will behave as if you had freed it.

* You can allocate memory allocated using memory-mapped files [2], a term which is distorted to include memory allocated by this mechanism but not necessarily backed by an actual file. These are not in the contiguous block of process data and their memory pages really are returned to the OS when the file is unmapped. This requires quite a lot of manual effort on the part of the developer, but for some applications it's worth it.

[1] https://en.wikipedia.org/wiki/Sbrk

[2] https://en.wikipedia.org/wiki/Memory-mapped_file
First question: probably some old MP3 from CDs I grabbed back in the good old Winamp days

Second: My CV I guess
“Have I been pwned?” creator Troy Hunt is doing an AMA on TNW on Wednesday
My hang gliding instructor, who was also an avid cyclist, explained that cycling is only dangerous because you spend so much time close to the ground.

This is a common joke in aviation, but sharing a thermal with multiple gliders whizzing around is a little disconcerting.
Neat. Got stuck watching Die Hard clips. Can I do all this from the CLI?
That isn't an exclusive or; the English language lets that be interpreted as either an xor or or, and the reasoning of the context shows it to be an or.

To iterate; the statement sets out two conditions, either of which are sufficient independent of the other, and claims that each of a number of services met one of those conditions.
Typical Apple fanboy link.
How ironic then that they sold to the very epitome of that example... and only speak out now, long after the $19B acquisition.
It would be sufficient to GET a resource that uses a script to POST the side-effect. Slack's user-agent probably isn't sophisticated enough to mess this up (although heaven help us when they implement their preview with something like headless chrome).
I have an iPhone SE because it has a headphone jack. But if the SE 2 doesn't have a headphone jack then this will be my last iPhone. My son wants to replace his iPhone, he's just waiting to see if the SE 2 has a headphone jack as well, or he will be switching to Android.

Some of us like being able to charge our phone and use it to listen to music in our cars using the AUX input of our car stereos. Plus have a wider choice of headphones that don't require constant charging.

And No, a dongle to get lost or broken is not an acceptable compromise.
Just be the guy who says "oh a POST is fine" first
Indeed, and I find my zinc/magnesium tablets an excellent way to induce it. I also find my 3000IU of vitamin D excellent in the other direction, for waking me up. Quite probably they’re both placebo, but it works, is safe in the amounts I take, and is cheap :)
For a while I tried using a blackberry that had android app support. One of the caveats was that the android support had no Google services support which rendered many apps unsable (including apps like Lyft that required Google maps).

I can’t imagine it’s gotten any better.
> Wouldn't an organisation such as Apple (who must be one of Qualcomm's largest customers, surely...) already share design information such as this with engineers inside Apple?

I don't see your point, and besides, Apple silos their information so that it's only available on a need-to-know basis.
while science isn't saying you should use magnesium for sleep per se

In the fitness community ZMA is widely considered a sleep aid.

https://en.m.wikipedia.org/wiki/ZMA_(supplement)
This is not just Watson and IBM. Many, many people in AI make grandiose claims and throw around big words like "Natural Language Understanding" "scene understanding" or "object recognition" etc.

And it is a very old problem, at least from the time of Drew McDermot and "Artificial Intelligence meets Natural Stupidity":

https://homepage.univie.ac.at/nicole.rossmanith/concepts/pap...

From which I quote:

However, in AI, our programs to a great degree are problems rather than solutions. If a researcher tries to write an "understanding" program, it isn't because he has thought of a better way of implementing this well-understood task, but because he thinks he can come closer to writing the _first_ implementation. If he calls the main loop of his program UNDERSTAND, he is (until proven innocent) merely begging the question. He may mislead a lot of people, most prominently himself, and enrage a lot of others.
It's funny how large sums of money will do that. I doubt I'd behave any better if I'm honest about it.
No one's saying they can't be allowed such a method. But it may be the case that for persistent business relationships doing so may mean an employee/employer relationship rather than the relationship between a business and an independent contractor.
Authenticating User with Truecaller SDK in Django
Is this new? I tried it out a couple years back on a decent spec phone and it was the slowest app I've ever used. I'm pretty sure Snapchat the app was known for being sort of a wreck at some point. My daughter still put up with it but it was painful to watch her use it.
> if you have the Safari "blank page" be your favorites instead of either your "home page" or a truly blank page.

Yay for modern user friendly applications making simple words like blank completely meaningless and ambiguous.
The Lawmaker from Silicon Valley Who Wants to Regulate Tech
...selling advertising via selling your users’ data for analysis is the easiest way to pay for the services but it’s at the cost of the users‘ basic privacy.

There must be a better way (albeit more difficult for the software company).

How about users actually paying for it? I’d pay a small amount
The Crisis of Method in Contemporary Analytic Philosophy
I'm not complaining about members of the public using a public road. I'm complaining about a company directing its users to take routes which were never designed as throughways; routes which few if any of those users would have taken but for Waze directing them.

Imagine you own a large parcel of land with a public easement for crossing to a beach. Every day a few dozen people walk across. Now imagine I put together a party and direct 3,000 friends to walk across your parcel all at once. As large crowds of people do, they stray and destroy things. Your mailbox. A small bridge crossing a creek that you own and maintain (thankfully nobody is hurt).

But for my party and the people I invited, none of this damage would have happened.

Not only did I create a credible nuisance (actionably by itself), it's not too much of a stretch to say I could be held vicariously liable for the damages. All this even though it was a public right-of-way.

In the absence of relief (self-policing, civil liability), I can tell you what is likely happen with the Waze issue. States will pass laws that require Waze and others to exclude routes upon notice by state authorities. A database will emerge of impermissible throughways. Neighborhoods and towns will scramble to add their streets to the database. Violations will come with huge fines whether or not actual harm occurs, even if the violation was exceptional (i.e. reroutes through blacklisted streets during a traffic accident). Ultimately the only routes you'll be given are truck routes.

This has already begun, it's just voluntary, and Waze doesn't cooperate. That's not going to last long. Waze will ruin the space for everybody else by inviting heavy-handed regulation.
What rhymes with 1337?: Computer poets are making headlines again
Thanks - we've merged the other comments into that one.
Yeah, full REST is nice, but you can do worse than just using GET and POST as long as GET doesn't change state.
Before you know you’re wrong most of the time you have to actually be wrong.

Cobol was first (or close to it) so it had to discover what “wrong” meant in the context of programming languages.

They had no way of knowing back then that having a programming language for non-programmers is a hard problem, close to impossible. Same goes for the natural language bit.

With the benefit of hindisght, yeah, we can make fun of it. It doesn’t make us right, though.
There was a movement in the UK that did exactly this (reclaim the streets, I think). They got infiltrated by the police!!
Drug related convictions are really mostly drug-related plea deals.

We know for sure that the convicts thought it safer to go to prison on drug charges than to go to court. We don't actually know whether they broke some other laws, and the DA simplified the paperwork. Seems to me that we ought to know this, before deciding what to do.
This Month in Google Assistant: April Recap
> The actual care if money is not an issue is the best in the world in the US.

That doesn't seem to be true across a range of indicators.
How? For ex. Tinder, We can only see some basic details about the person. How can we know about
the behavior or his/her likes. For ex. If given a choice between Ice-cream and Chocolate, which one s/he would prefer.
Does there exist an app where we can match based on our choices?
What would the problem be in just showing a button that says "Confirm unsubscribe" that sends a POST request? A lot of sites does something like that for their newsletter unsubscription.
Photographic lighting is such an overlooked skill. Commercial photographers spend years crafting this skill. You can spend hundreds of thousands of dollars just on lighting, where one umbrella reflector, with no electronics, can cost $11k.

Here's an example of an iPhone product shot: https://fstoppers.com/video/bts-how-apples-product-photograp...

Each specular highlight & complementary shadow contrast is put in on purpose, with its own lighting/card/reflector.
I hope this doesn't come across as mean-spirited, but I'm really struck by the middle part of your comment, even though I think it was meant as a throwaway remark.

It sounds like you're advocating leaving an organisation instead of speaking up when a mistake is being made? In the scenario you described, the "a GET is fine" person is unfamiliar with the protocol they're writing for (HTTP), and so is every person who agreed. Leaving instead of speaking up seems pretty drastic.
Yeah, but how will you figure out the business logic? That comes from regulation, business requirements from 20 years ago, etc. It’s archaeology.
CTFtime.org inactive for about 2 weeks
https://ctftime.org/lastlog
A bash file that does a backup of selected directories to an external disk. It's about 340 lines of shell that manages saving to dated target directories using rsync and using links to unchanged files Also performs a target filesystem sanity check and won't run if the wrong external disk is mounted. Been using it for many years on Linux and Mac.
JS isn't in shambles; in fact, their package manager situation is excellent: Use yarn, period. It could be better (yarn isn't default yet), but I would love for the Python ecosystem to get to: "Use pipenv and setup.cfg, period".

But as I said, it's too young. If you use pipenv, you still have to interact with pip, so that's two binaries whose commands you have to remember. And urgh, it's so slow. And it's kinda useless for libraries... pipenv doesn't publish stuff, pipfiles aren't appropriate for packages.

But we'll get there. One day. Hopefully it won't be too late.
One more thing: PATCH needs to do atomic updates on a partial resource per http://restcookbook.com/ (which I think is a great TLDR resource on the topic).