The Functor Pattern in C++ - <AUTHOR> http://fpcomplete.com/the-functor-pattern-in-c/

<comment><USER2> C++ is a powerful language, but with awful syntax and semantics that can discourage experimentation. Since I started using Haskell just over a year ago, my C++ code is much improved—because I can figure things out quickly in Haskell, then translate them to (somewhat write-only) C++. That I think is a large part of what people mean when they say "Haskell makes me a better programmer". Not only is it a good language in its own right, but it also helps you prototype software that you need to implement in another language for reasons other than language power.

<comment><USER3> "C++ is a powerful language, but with awful syntax and semantics that can discourage experimentation."

Then you should try out D. Bartosz Milewski in fact has been involved in D development for a long time. It certainly makes it easier to apply a lot of the FP techniques.

<comment><USER2> I have experimented a little bit with D, and really like some of the things in the standard library, but Haskell is already serving as my replacement for C++. D is a viable alternative to C++ for most purposes, though.

I'm actually working on a compiler for a high-performance functional language, to serve in those cases when I would want to go back to C++…

<comment><USER4> I'm working on-and-off on something similar, would you excuse a few questions?

Is it statically typed? Do you have ADT support and/or an object system? GC / refcounting or manual memory management?

How are you implementing bind() and currying in a compiler? I'm targeting x86 and my approach is to make little stubs on the heap that push a single parameter, then i can throw them around as ordinary function pointers (lambda lifting every single parameter rather than looking up things through environment pointers at runtime). The problem with this is that i end up with a huge amount of small fixed-size objects on the heap, which is a little less than ideal but at least i can write a special allocator for that case.

EDIT: Upon a little background reading (and your illuminating february blog post on concatenative languages) i realise you're probably referring to Kitten, in which case i'm not sure any of my current questions are remotely applicable.

<comment><USER2> I am moving from dynamic to static typing. Unfortunately the `compose` primitive has a rank-2 type in the general case, so you need explicit type annotations for many higher-order functions. I am supporting ADTs, which are basically identical to quotations under the hood. There will be an object system in the standard library once I figure out a good object model. Memory management is done through plain old refcounting. Some programs may benefit from waiting for the next push before deallocating popped values, but I have yet to profile to find out.

As you may have realised, currying doesn't really apply to concatenative languages because they lack application. The analogue of partial application is deferred composition, i.e., just concatenating quotations:

        [1] [+] compose  [1 +]  =

I've been working on the language actively, but haven't pushed code lately. Do watch the repo[1] if you're interested, though, and link me to yours. I also think I know you from #esoteric or something? My memory sucks and I haven't been on there lately.

[1] <https://github.com/evincarofautumn/kitten>

</comment></comment></comment></comment></comment><comment><USER5> std::function is really nice. I've started using it everywhere.

<comment><USER2> If only it didn't use dynamic allocation…ah well. The value is worth the cost.

<comment><USER6> I don't think std::function does any dynamic allocation when you initialize it with simple functions. When you initialize it with function objects or lambda expression, most, if not all implementations use the small object optimization to avoid dynamic allocation when possible.

<comment><USER7> With function objects the GNU std::function does do dynamic allocation. Even for objects as small as an empty struct.

</comment></comment></comment></comment><comment><USER8> ...or why types and the lack of anonymous functions combine to make a language painful, ugly, and annoying.

<comment><USER9> C++11 does have anonymous functions

<http://www.cprogramming.com/c++11/c++11-lambda-closures.html> [http://stackoverflow.com/questions/7627098/what-is-a- lambda-...](http://stackoverflow.com/questions/7627098/what-is-a-lambda- expression-in-c11)</comment></comment>


Preventing the Collapse of Civilization [video] - <AUTHOR> https://www.youtube.com/watch?v=pW-SOdj4Kkk <comment><USER2> At what point in the past were our programs stable, robust and just worked? Perhaps it was before my time, but DOS and windows (3.11, 95) would crash, constantly. Blue screens of death, infinite loops that would just freeze my computer, memory leaks that would cause my computer to stop working after a day.

I now expect my computer to stay on for months without issues. I expect to be able to put it to sleep and open it in the same state it was. I expect that if a website or a program errors, my OS simply shrugs and closes it. I expect my OS to be robust enough so that if I enter a usb or download a file I'm not playing Russian roulette that it might contain a virus that would destroy my computer.

In the past I would close my computer at the end of every day because otherwise it will simply crash some time in the night. I would run de fragmentation at least once a month. Memory errors and disk errors were common, and the OS had no idea how to overcome it. Crashes were so common, you just shrugged and learned to save often.

<comment><USER3> > At what point in the past were our programs stable, robust and just worked?

DOS was rock solid, at least around the era of DR-DOS. DESQView 386 was absolutely stable too. The BBS software I ran on them in those days was a wobbly piece of shit though.

I also recall Borland's Turbo Pascal compiler and the accompanying text-mode IDE being ultra reliable.

After DOS I've used OS/2 which was also extremely stable, although suffered from limited hard- and software availability.

Mac OS X used to be rock solid too in the heydays of the Powerbooks and earlier Intel Macbooks. Every now and then there were hardware design flaws though, and now the quality of both soft- and hardware seems to have taken a tragic turn for the worse.

You still do play Russian roulette whenever you plug a USB device into your computer, see "USB Rubber Ducky".

<comment><USER4> > DOS was rock solid

DOS was rock solid because it did nothing. Many programs, particularly games and anything that did networking, didn't even use DOS interfaces—they bypassed them entirely and worked with either the BIOS or hardware directly. There was no memory protection, no multitasking, and, on a higher level, no permissions nor sandboxing. So while maybe it "just worked", I wouldn't call it robust.

<comment><USER5> You're complaining that DOS lacked features and protections. But zero cost abstractions like DOS can still be robust (in the sense of being reliable and solid.) yes it requires more trust, But there is no guarantee modern OSes can run arbitrary zero-trust binaries.

<comment><USER6> If you run a buggy program on a modern OS, it won't crash the system or impact other processes. If you run a buggy program on DOS, it will write to random physical addresses, probably clobbering the state of other processes and of DOS.

Modern OSes can run arbitrary binaries, but they can pretty much run arbitrary non-adversarial binaries - problematic binaries have to be intentionally written to exploit the system (as opposed to DOS, where non-problematic binaries had to be intentionally written to not break the system).

It's a dramatic improvement.

<comment><USER7> It doesn't matter what OS I run. My "modern", and apparently buggy, CPU runs arbitrary systems that I know very little about, and I have little to no control over.

Since 2008, it's been a dramatic departure.

</comment></comment></comment></comment></comment></comment><comment><USER8> As a JavaScript developer I strongly resonate with the quote at 14:50 into the video. In summary all of the silicon industrys' chips at the time were full of defects and often the same defects between various vendors. The industry was completely aware of this. The problem is that the original generation of chips were designed by old guys who figured it out. The current generation of chips (at that time) was designed by youngsters working in the shadow of the prior generation and not asking the right questions because they were not aware of what those questions were.

A decade ago JavaScript developers had little or no trouble working cross browser, writing small applications, and churning out results that work reasonably well very quickly. It isn't that cross browser compatibility had been solved, far from it, but that you simply worked to the problem directly and this was part of regular testing.

That older generation did not have the benefit of helpful abstractions like jQuery or React. They had to know what the APIs were and they worked to them directly. The biggest problem with this is that there weren't many people who could do this work well. Then shortly after the helpful abstractions appeared and suddenly there was an explosion of competent enough developers, but many of these good enough developers did not and cannot work without their favorite abstractions. These abstractions impose a performance penalty, increase product size, impose additional maintenance concerns, and complicate requirements.

The ability to work below the abstractions is quickly becoming lost knowledge. Many commercial websites load slower now than they did 20 years ago despite radical increases in connection speeds. To the point of the video this loss of knowledge is not static and results in degrading quality over time that is acceptable to later generations of developers who don't know the proper questions to ask.

<comment><USER9> Actually, I don't think that abstractions are the problem. I mean, the whole OSI model is made of abstractions. Abstractions are at the core of software development.

And I also don't think that Jquery is the problem. Jquery just made JS worth learning. Before you had to spend an insane amount of time just working out implementation specifics that changed every few months.

However, the point where I do agree with you is that we have a performance issue with JS. And I am not talking about slow JS engines. I am talking about developers who are not aware of how costly some operations are (e.g. loading a bunch of libraries). Yes, that is an issue that naturally arises with abstractions, but to conclude that abstractions themselves are the problem is wrong.

I think the problem is more about being aware of what happens in the background. You don't have to know every step for every browser and API, but loading 500KB of dependencies before even starting your own scripts is not going to be fast in any browser.

<comment><USER8> The abstractions aren't making this problem the developers without a willingness to work under the abstractions are.

I wrote this following tool in less than 90 minutes 5 years ago because I had some time left over before presentations at a company hack-a-thon. I updated it recently at about another 90 minutes of time.

[https://github.com/prettydiff/semanticText](https://github.com/prettydiff/semanticText)

That tool was trivial to write and maintain. It has real utility value as an accessibility tool. I could write that tool because I am familiar with the DOM, the layer underneath. Many developers are not even aware of the problems (SEO and accessibility) this tool identifies much less how to write it. jQuery won't get you the necessary functionality.

<comment><USER10> Why are so many of your comments of a gate-keeping, self-congratulatory nature, or blanket criticisms of others?

I find it frustrating because I _do_ think you have plenty of valuable stuff to say, but you're consistently presenting it in a rather unappealing package and I don't really understand what you get out of that.

<comment><USER8> Gate-keeping yes, self-congratulatory no. This subject is personally sensitive to me because it has immediate real world consequences that impact my livelihood and choice of employment.

I am away from home on a military deployment at this time and I am constantly thinking about what I should do when I return to the real world. I am actively investigating career alternatives by dumping software development, because I honestly believe my career is limited by the general unwillingness of my development peers to address actual engineering concerns out of convenience and insecurity.

</comment></comment></comment></comment></comment><comment><USER11> Great talk. I agree that sw is on the decline. You can see it in your OS, on the web, everywhere. Robust products are replaced with 'modern' crappy redesigns. We are surprised if the thing still works after 5 years.

I don't agree on his conclusions. The real source of problem is that now we have maybe x100000 more software than we had in 70s. It's that many more programmers, so not just the 1% smartest greybeards as before. We need more abstractions, and yes, they will run slower and have their issues.

Also, not everybody is sitting at the top of hierarchy of abstractions. Some roll up their sleeves and work on JIT runtimes and breakthrough DB algorithms.

All those blocks of software need to communicate with the platform and between them. IMO the way out is open source. Open platforms, open standards, open policies. Every time I found a good piece of code in company's huge codebase, it was open source library. Every time. You have to open up to external world to produce well engineered piece of software. The lack of financial models for open source is the obstacle. We should work on making simple and robust software profitable.

<comment><USER12> > The real source of problem is that now we have maybe x100000 more software > than we had in 70s. It's that many more programmers, so not just the 1% > smartest greybeards as before.

The greybeards from the 70s weren't much smarter than today's programmers. They were the same curious hackers from today, with the advantage of being born in the right place at the right time, when the technology was still developing, so they were forced to build their own tools and operating systems.

> We need more abstractions, and yes, they will run slower and have their > issues.

I disagree, and side with Jon Blow on this: abstractions (if done well) create the illusion of simplicity and more often that not hide the apparent complexity of lower levels. Sometimes this complexity is indeed too difficult to work with, but often it's the problem itself that needs to be simplified instead of creating an abstraction layer on top.

I think as an industry we've failed to make meaningful abstractions while educating new programmers on the lower level functionality. A lot of today's programmers learned on Python, PHP, Ruby, JavaScript, etc., which are incredibly complex tools by themselves. And only a minority of those will end up going back and really learning the fundamentals in the same way hackers in the 60s and 70s did.

> IMO the way out is open source. Open platforms, open standards, open > policies.

Agreed. But education and simplification are also crucial.

<comment><USER11> The argument wasn't that people were smarter back in 70s. Instead, computers were rare, only the most motivated individuals could reach them. They were curious hackers as you say, and today's curious hackers are just as good. They form maybe 1% of programmer population.

Regarding abstractions, I feel you are talking about leaky abstractions - systems that offer a simplified interface but still manage to burden you with all the implementation details. It's hard to identify such poorly engineered building blocks until it's too late. Thus layers get built on top of them and it becomes too costly to go back and rework the stack. This is a problem with development processes favoring new features over paying the accumulated tech debt.

Still, good building blocks can exist. You can (and often must) have complexity if it's properly isolated and does not leak. I'd say JVM is great example of abstraction that is slower and internally more complex than SW done native, but brings much to the table as a platform to build on. Other examples: BeamVM, ZeroMQ, Lua (leaky, but at least very simple). Browsers unfortunately are too burdened with legacy and security issues.

I feel my formal education has failed to teach me how to design proper interfaces between systems. Instead we are taught pointer arithmetic and mainstream OOP ("cat IS an animal").

</comment></comment></comment><comment><USER13> It seems to me that there is a cultural problem that deep expertise is not valued, because it is difficult to understand and to get somebody "flexible" is easier.

I was just at a workshop about [https://en.wikipedia.org/wiki/Design_thinking](https://en.wikipedia.org/wiki/Design_thinking). The whole premise was that you don't actually need to hire an (expensive, inflexible) expert, who understands how something is done, but rather what you need to do is to "observe" an expert.

But imagine what happens when everybody does that! Everybody gets rid of their experts, assuming that the client (who they are supposed to provide the service for) has the actual expertise. And they are assuming the same about their clients and so on. The end result is complete disregard for expertise.

So expertise is a positive externality, in an economic sense. Nobody is incentivized to keep it more than neccessary. This leads to losses over time.

<comment><USER14> This is very common in industry with boom/bust cycles. Lots of experts in the boom, they leave when the bust comes, then when the next boom comes there are lots of problems expanding said processes quickly because of lack of expertise.

</comment></comment><comment><USER15> The risk is that things 'just work' for extended periods of time and the maintainers are optimised out of the system because they aren't needed in the short term.

My personal guess at why civilisations can collapse so slowly (100s of years for the Romans, for example) is that the people who maintain the political systems do too good a job, and so the safeguards are forgotten.

For example, after WWII the Europeans learned some really scary lessons about privacy. The Americans enjoyed greater peace and stability, so the people with privacy concerns are given less air time in places like Silicon Valley or Washington. The two-step process at work here is that when things are working, standards slip and the proper response to problems are forgotten. Then when things don't work, people don't know what to do and the system degrades.

<comment><USER16> Sean Carroll's podcast Episode 37: Edward Watts on the End of the Roman Republic and Lessons for Democracy has good discussion about this (there is also transcript) [https://www.preposterousuniverse.com/podcast/2019/03/11/epis...](https://www.preposterousuniverse.com/podcast/2019/03/11/episode-37-edward- watts-on-the-end-of-the-roman-republic-and-lessons-for-democracy/)

Basically there are norms and unwritten understanding, deeply understood ideas about what is not acceptable. Rulers don't push their power to full extent. Then someone comes along and starts to push them and gradually what is acceptable changes.

</comment></comment><comment><USER17> I loved this talk, and in particular the point about programmers being forced to learn trivia instead of deep knowledge. I just started a new job at a big tech company, and I've spent a whole week so far trying to figure out how to use the build tool. The frustrating part is that most of the software modules my team is working on aren't very complicated. The complexity comes from pulling in all sorts of 3rd party libraries and managing their transitive dependencies.

</comment><comment><USER18> He briefly mentions the Boeing 737 MAX issue, but he understates the problem. Sure there was a software problem, but the urderlying issue was the whole notion that everything can be "fixed" (worked around) by software. That it's fine to make changes to the plane aerodynamics and compensate with software so that it would seemingly act like the previous model.

<comment><USER19> I'm reminded of this explanation that was posted on HN couple months back [https://twitter.com/trevorsumner/status/1106934362531155974](https://twitter.com/trevorsumner/status/1106934362531155974)

Seems like it was a physical engineering and business problem and software was added to (inadequately) compensate.

</comment></comment><comment><USER20> He obviously uses Windows for his anecdotal examples, but I don't think you can point the finger at Windows specifically. I think it's consistent throughout OSes. I see regressions in iOS since the earlier versions, as well as in Linux and the applications I use.

My IDE stopped providing menus. It's open source so I just shrug and track the issue in Github.

</comment><comment><USER21> Fantastic talk.

Portable Apps on Windows are a hedge against some of the angst he describes. (E.g. the part about updates changing a lot of things around or causing failure-to-launch problems).

E.g., I still use WinAmp to play mp3's. It's a portable version, doesn't need installation (so I can use it on my locked-down work computer). The UI hasn't changed in 20 years. Newer file-formats can be played after adding plug-ins.

I've put together a whole bunch of Portable Apps, and nowadays I first try to find a portable version of an app I need before a non-portable version.

<comment><USER22> 100% concur re: portable apps. It's a better way to live from an end-user standpoint in my experience. Portableapps.com and librekey both are excellent

</comment></comment><comment><USER23> The repeal of Moore's law will be a blessing in disguise, I think. Not only will programmers need to get clever in a traditional sense but, also, a new era of specialized hardware will require a more intimate understanding of the bits and pieces. I'm optimistic.

<comment><USER24> I'm actually looking forward to the end of Moore's Law. Instead of keeping up with a rapidly shifting landscape of new and creative ways of wasting CPU cycles, we can maybe build things that have a chance of lasting a hundred years.

<comment><USER14> Even after Moore's we are going to have a shifting landscape of security changes in processors that has been neglected for some time.

</comment></comment></comment><comment><USER25> At my workplace when I ask about why some process parameters are this way it usually leads to a dead end where the people who know are long gone and those who should know don't know the essentials. Everything is kind of interconnected and errors show up months later so you can't really change anything on any machine until the machine as a whole breaks and needs to be replaced. Then you try to get it to work somehow and those parameters are then set forever.

</comment><comment><USER26> The general purposeness of computers is the reason for complexity. We use the same systems to do highly secure and critical business transaction as high performance simulation, playing and fun. The conveniency of not having to switch systems when doing different tasks is adding a lot of complexity. Special purpose hardware can by its nature of not being general, be much simpler and omit a lot of the security and complexity. But it's much less convenient and much less flexible.

</comment><comment><USER27> I think it's because companies always try to commoditize software developers but it doesn't work. You can't replace a good software developer with 10 mediocre ones plus thousands of unit tests. The only way to become a good software developer is with experience.

</comment><comment><USER28> I remember seeing the foundationDB distributed systems testing video for the first time, and being blown away with what it takes to build robust software. Worth a view if you haven't seen it. [https://www.youtube.com/watch?v=4fFDFbi3toc](https://www.youtube.com/watch?v=4fFDFbi3toc)

Would love to see more things in this direction, but, I agree that the market doesn't want it. Most users will gladly accept an infrequent bug for an earlier release, or lower cost version of a product.

</comment><comment><USER29> Reducing all this complexity is partly why I'm hoping the Red Language project can succeed where Rebol failed.

Of course you can't do everything, but a good full-stack language could cover perhaps 80% of software needs using well written DSLs. The simple fact that we have so many languages targeting the same thing is a waste and duplicative effort (Java, C#, Kotlin, Scala, Clojure, F#...etc) for business apps and (Python, Matlab, Julia, R, and Fortran) for data science and scientific programming. Also systems languages like (C, C++, Ada, Rust).

On one side it is good to have purpose built languages, but on another it puts a big barrier to entry.

Note that I'm advocating for abstractions, but far fewer languages. Yes, abstractions add complexity, but actually make the code more readable. I shudder to think of humanity having to maintain and support ever increasing levels of software.

<comment><USER17> I absolutely agree that we actually need fewer languages. The languages we have today really are good enough for the vast majority of programming work. To the extent that they fall short, the solution is to either improve the language or to build good libraries for it.

<comment><USER30> Many programming languages start out as 'experiments' by their creators, to combine or extend the capabilities and attributes of some prior ones.

That seems like a very healthy evolutionary approach to me.

</comment></comment></comment><comment><USER31> This whole presentation feels like a great candidate for a meta analysis on the effects of recency bias on analysis.

</comment><comment><USER32> I challenge his assertion around 32:50 that something is lost. I've done assembly programming. C programming. I might venture to say I'm pretty good at it. I even dabbled a bit in baremetal programming, was going to make my own OS, but lost interest. Wanna know why? Take a look at this[1] article. Yep. If, on x86, you want to know what memory you're allowed to access; how much of it and where it is, there is literally no good, or standard way to do that. "Well," you (or jon blow) might say, "just use grub (or another multiboot bootloader), it'll give you the memory map." But wait, wasn't that what we were trying to avoid? If you do this, you'll say "I'm smart, I'm sparing myself the effort," but really there is a loss of capability, you don't really know where these BIOS calls are going, what the inner workings of this bootloader are, and something is lost there.

This is a bit of a contrived and exaggerated example, but it serves to prove my point which is that these things really do scale linearly: you give up the same amount you get back by going up a layer of abstraction (in understanding/productivity, not talking about performance yet). Low-level programming languages aren't more productive than high-level programming languages. Low-level _programmers_ are more productive than high-level ones because it takes more discipline to get good at low-level programming so the ones that make it in low-level programming are likely to be more skilled or, at least, to have acquired more skill. Think about the story of mel[2]. Does anyone honestly think, with any kind of conviction, that mel would have been less productive had he programmed in python and not thought about how machine instruction would be loaded?

As I've mentioned, I have done, and gotten reasonably good at, low-level programming, and yet my current favourite language is perl6. A language that is about as far from the cpu as it gets, on a par with javascript or haskell. Why? Because _nothing is lost_. Nothing is lost, and quite a lot is gained. There are things I can do with perl6 that I _cannot do_ with c—but, of course, the reverse is also true. And I think that jon blow's perspective is rather coloured by his profession—game development—where performance is important and it really does pay, sometimes, to think about how your variables are going in memory. He has had, I'm sure, negative interactions with proponents of dynamic languages, because he sees their arguments as (maybe that's what their arguments are, I don't know) "c is useless, javascript is good enough for everything." Maybe the people who truly think that have lost something, but I do not think that mel, or jon blow, or I, would lose much by using perl6 instead of c where perl6 is sufficient.

1: [https://wiki.osdev.org/Detecting_Memory_(x86)](https://wiki.osdev.org/Detecting_Memory_\(x86\))

2: [http://www.catb.org/~esr/jargon/html/story-of- mel.html](http://www.catb.org/~esr/jargon/html/story-of-mel.html)

<comment><USER33> About the first one, that's also another problem, BIOS doesn't have standard protocol, if there would be such, there would be one standardized way to detect the memory layout.

About the second one, performance should be crucial everywhere, if some application eats all the resources then I can't have other applications working in the background doing their stuff. That's the problem with i.e. "modern" communication apps (I'm talking about you, slack) where my four core CPU is on it's knees when doing simple things like switching the team or even channel, not mentioning starting the app itself. Another one is when I'm on the Google Meet chat, my browser eats 80% of CPU, I can't do anything reliably in that time, running anything makes chat to loose audio, lag a much, etc.

Going back some years ago, I was able to run Skype, AQQ, IDE, Chrome browser and Winamp at the same time on archaic (in today's standards) i3-350M and 4 GiB of RAM.

<comment><USER34> > About the first one, that's also another problem, BIOS doesn't have standard > protocol, if there would be such, there would be one standardized way to > detect the memory layout.

It's the same for almost all hardware: graphics cards, sound cards, all use their own register map (which, to make the matter worse, is often kept secret). Even USB stuff, which is supposed to be already homogeneized (i.e USB classes) often requires sending vendor-specific "quirk" strings to get the hardware working (e.g the list of 'quirks' in the snd-usbmidi Linux kernel module).

The hardware diversity isn't a detail here. It's the root of the "too many abstractions" problem, and I don't think this is something you can avoid. This is why device drivers exist. This is why operating systems try hard to impose APIs on device drivers (ALSA, Direct3D, etc.) so Firefox, MS Word, Half-Life ... can run on future hardware.

This is one reason why the abstraction layers exist (I'm not even talking about memory protection / safety here) : because you don't want to re-release your app every time some vendors makes a new sound card, graphics card, MIDI interface, wi-fi chip, etc. And you don't want to code the support for all this hardware yourself.

</comment></comment></comment><comment><USER35> There is a relationship between quantity of functionality and bugginess. Even with the most demanding testing, bugs will remain. The question is, as more and more software permeates our lives, will the accumulation of unfixable bugs ultimately overwhelm us. Can we build an AI that can clean enough of the bugs out of all of our software, including it's own, for our civilization to survive?

</comment><comment><USER36> It seems like Jonathan Blow completely forgot about the blue screen of death and how common it was.

</comment><comment><USER37> Now, what would be amazing would be if we had found the Antikythera mechanism so intact that it could be reconstructed perfectly. And then we'd check everything it could do, and what kinds of drawbacks or errors the construction had!

</comment><comment><USER32> People don't care about five 9s anymore? It's not _as_ important as it was (I assume—I wasn't really around at the time), but cloud providers definitely advertise their number of 9s.

<comment><USER38> Good thing they have regular service outages that mysteriously don't quality for SLA (or show up on dashboards)

</comment></comment><comment><USER39> I had a few cocktails and thought about a few points made in the video.

It seems to me that there are two different notions here that are being conflated:

. A rotting of knowledge over time.

. A variant of Moore's Law. In this case, the idea that the value of technology, in a particular area, has a decreasing value on the margin.

It's kind of like the notions you see in cliodynamics, that there are a few interacting sine waves (or some other function) in mass human behavior.

I suppose that the main concept of importance is how it all might mess with your own personal situation. Personally, I think that the West is in decline, but that doesn't have a whole lot to do with the quality of software on internet websites.

</comment><comment><USER40> There is no preventing a collapse. Try and enjoy the ride :)

</comment><comment><USER41> I was with him until the middle.

Lack of inter-generational knowledge transfer doesn't cut it. Most of the people who rolled this stuff are still alive. And as for the whipper-snappers: people don't get very far writing programming languages/video games/operating systems without knowing their stuff.

The real boogeyman is feature combinatorics. When making a tightly-integrated product (which people tend to expect these days), adding "just" one new feature (when you already have 100 of them) means touching several (if not all 100) things.

Take OpenBSD for example: When you have a volunteer project by nerds for nerds, prioritizing getting it right (over having the fastest benchmark or feature-parity with X) is still manageable.

Bring that into a market scenario (where buyers have a vague to non-existent understanding of what they're even buying), and we get what we get. Software companies live and die by benchmark and feature parity, and as long as it crashes and frustrates less than the other guy's product, the cash will keep coming in.

<comment><USER42> > _When making a tightly-integrated product (which people tend to expect these > days)_

Do they? It was my impression that the recent evolution of user-facing software (i.e. the web, mostly) was about less integation due to reduced scope and capabilities of any single piece of software.

> _adding "just" one new feature (when you already have 100 of them) means > touching several (if not all 100) things._

This sounds true on first impression, but I'm not sure how true it really is. Consider that I could start rewriting this as "adding 'just' one new program when you already have 100 of them installed on your computer"... and it doesn't make sense anymore. A feature to a program is like a program to OS, and yet most software doesn't involve extensive use, or changes, of the operating system.

The most complex and feature-packed software I've seen (e.g. 3D modelling tools, Emacs, or hell, Windows or Linux) doesn't trigger combinatorial explosion; every new feature is developed almost in isolation from all others, and yet tight integration is achieved.

<comment><USER41> Pretty sure making emacs render smoothly in 2016 was not an isolated change-- even if the code change were only a single line.

[https://www.facebook.com/notes/daniel-colascione/buttery- smo...](https://www.facebook.com/notes/daniel-colascione/buttery-smooth- emacs/10155313440066102/)

Same story for speeding up WSL.

[https://devblogs.microsoft.com/commandline/announcing- wsl-2/](https://devblogs.microsoft.com/commandline/announcing-wsl-2/)

Or, just think about your phone. If I put my head to the speaker, a sensor detects that, and the OS turns off the screen to save power. If I'm playing music to my Bluetooth speaker, and a call comes in, it pauses the song. When the call ends, the song automatically resumes.

KT's UNIX 0.1 didn't do audio or power management or high-level events notification.

<comment><USER42> > _Pretty sure making emacs render smoothly in 2016 was not an isolated change > --even if the code change were only a single line._

This was a corner case. What I meant is the couple dozen packages I have in my Emacs that are well-interoperating but otherwise independent, and can be updated independently.

> _Or, just think about your phone. If I put my head to the speaker, a sensor > detects that, and the OS turns off the screen to save power. If I 'm playing > music to my Bluetooth speaker, and a call comes in, it pauses the song. When > the call ends, the song automatically resumes._

These each affect a small fraction of code that's running on your phone. Neither of them is e.g. concerned with screen colors/color effects like night mode, or with phone orientation, or with notifications, or countless other things that run on your phone in near-complete independence.

<comment><USER41> Buttery smooth emacs is not a corner case. When working on API-level things (for those who don't know--emacs is practically an operating system), if we care about not breaking things, one must be highly cognizant of all the ways that API is consumed. Even if the final change ends up being very small code- wise, the head-space required to make it is immense. That is why we have (relatively) so few people who make operating systems and compilers that are worth a damn.

Most emacs plug-ins aren't operating at that level of interdependence. This one is working on a text buffer at t0, and that other one is working on a text buffer at t1. Of course, the whole thing can be vastly simplified if we can reduce interdependence, but that is not the way the world works. Typical end user doesn't want emacs. Typical end user wants MS Word.

Even if I accepted the replacement of my word "feature" with your word "program" (not that I do), one only needs to look at Docker's prevalence to see the point still holds. Interdependence is hard, and sometimes unavoidable.

</comment></comment></comment></comment></comment><comment><USER43> bravo, great talk Jon. but real talk can you make another Braid already

</comment><comment><USER44> Not to pick on Microsoft specifically too much, but I remember seeing the hello world program for windows 3.1 for the first time and thinking, "this is not looking good." And I was right.

</comment><comment><USER45> Wow he has a rosy picture of the past. I don't see where he gets the five nines from. He doesn't even quote anybody on it. Most of the examples he gives would have been zero nines back in the day because they were not available at all!

Wikipedia for example has one nine availability in my life. Because when I sleep my phone is still on.</comment>


Western Digital not following the GPL? - <AUTHOR>

So, I needed to update the firmware of my external WD drive today and I found out that WD graciously provides a firmware updating application for Macs as well (http://www.wdc.com/wdproducts/wdsmartwareupdate/firmware.asp?id=wdfMP_Ultra&os=MAC -> "Download now" or http://www.wdc.com/global/webtracking/index.asp?id=1181&url=http://download.wdc.com/fwupdater/Mac/WDFirmwareUpdater.zip for the direct link).
Being the nosy person I am, the first thing I've done was to see inside the application package and guess what:
~/WDFirmwareUpdater.app> find . -iname "*.h" -type f -print | xargs grep "GNU General Public License" ./Contents/Frameworks/WDUIKit.framework/Versions/A/Headers/StillCapturer.h://  it under the terms of the GNU General Public License as published by ./Contents/Frameworks/WDUIKit.framework/Versions/A/Headers/StillCapturer.h://  GNU General Public License for more details. ./Contents/Frameworks/WDUIKit.framework/Versions/A/Headers/StillCapturer.h://  You should have received a copy of the GNU General Public License
So far I haven't found any source bundle from WD for said framework but this looks like an obvious GPL violation to me - and good job with release control there guys, leaving the .svn directories around was just the finishing touch :) <comment><USER2> I found a bunch of pages on their site for GPL compliance, including [http://support.wdc.com/product/download.asp?groupid=902&sid=...](http://support.wdc.com/product/download.asp?groupid=902&sid=132&lang=en) .

<comment><AUTHOR> Seems like that stuff doesn't cover the firmware updater. The infringing code is dated 2006, those files are from 2001 or so.

WDC opensourced all the GPL code inside the firmware for their "smart" (read: linux-based) product, not their desktop code (see also: [http://support.wdc.com/download/gpl/](http://support.wdc.com/download/gpl/))

[edit: added info]

<comment><USER2> Still, it seems they're putting the effort in, and it would seem to be a better solution to simply email them and ask.</comment></comment></comment>


Palm's Open Source Portal is now available - <AUTHOR> http://pdnblog.palm.com/2009/06/palms-open-source-portal-is-now-available/ <comment><USER2> I'm really glad that Palm is making the tarballs available without requiring some stupid developer login on yet another site - a lot of places could learn from this good example.

Hopefully they do a better job of maintaining their developer community this time around - if they do, they could grow into a wonderful force for open source good.

<comment><USER3> I hope they don't do what Apple used to do -- dump all their KHTML changes as a huge diff and call it "WebKit", but actively participate in the development of the products. See what happened with WebKit once it got a community, it's now one of the best desktop engines, and the best mobile web engine by far.

</comment></comment><comment><USER4> From the title, I thought Palm had developed an open source version of the Valve game.</comment>


Blockchain. Is It Worth Your Attention? - <AUTHOR> http://www.softengi.com/blog/blockchain-hot-or-not <comment><AUTHOR> Blockchain is now one of the most hyped, hotly debated, controversial, and yet promising technologies since the inception of the Internet. It is often mentioned in Gartner, Forbes, the Economist, and other reputable resources. Indeed, this cutting-edge technology has the potential to trigger a revolution in a significant number of industries! Of course, as with any system, Blockchain has many advantages and disadvantages. This [Blog Post] sheds light on some of them. Read it to decide whether Blockchain is worth your attention.</comment>


Arista, Uber, Silicon Valley - <AUTHOR> http://om.co/2014/06/08/arista-uber-silicon-valley/

<comment><USER2> _" Microsoft loves it so much that it now makes up about ten percent of their revenue."_

What?

<comment><USER3> Microsoft buys their gear..?</comment></comment>


Show HN: PinPigeon for Pinterest - Send pins as postcards - <AUTHOR> https://chrome.google.com/webstore/detail/pinpigeon-for-pinterest/bokbjgfakkhkllopnpdpmpehhilhdple

<comment><USER2> Love seeing people use the Sincerely api. I truly believe in Hiring via API <http://www.mattbrezina.com/blog/2011/08/hiring-via-api/>

</comment><comment><USER3> This reminds me of my friend's product <http://www.scribblepics.com/> (but they do it through mainly big tourism type partnerships rather than directly b2c).

</comment><comment><USER4> Pinterest user's pin with the "promise" that they own the content. Well we know that's not happening. But what happens when PinPigeon prints images with copyrighted content from Coke, Budweiser, Apple, etc? Or, less identifiable but equally protected?

</comment><comment><AUTHOR> built & shipped today

<comment><USER5> congrats. I like this trend of being able to ship physical things with a click of a button. it's the new "cloud"</comment></comment>


Physical explanation of Dijkstra's algorithm (2011) [video] - <AUTHOR> https://www.youtube.com/watch?v=2E7MmKv0Y24&feature=youtu.be&t=29m38s <comment><USER2> The unanswered question is, whether this always works with any metric that works with Dijkstra.

And the answer, I guess, is no. Dijkstra works with negative edge weights (although no negative loops). This doesn't translate to string. Also there are some other restrictions like that any edge is always symmetric where with Dijkstra it needn't be. A>B (3) and A<B (5) would be the lower for both with regards of the physics.

Edit: But it seems like for undirected graphs, the edge weights are always positive and by definition symmetric which is sufficient that string-dijkstra works.

<comment><USER3> Textbook Dijkstra doesn't work with negative edges. See for example

[http://stackoverflow.com/questions/6799172/negative- weights-...](http://stackoverflow.com/questions/6799172/negative-weights- using-dijkstras-algorithm)</comment></comment>


Show HN: I'm building a single source of truth for immigration pathways - <AUTHOR> https://www.duoflag.com/destinations/ <comment><USER2> I like the idea! Few notes I noticed that could bring you some value somehow/someday:

\- It would be interesting in the future to partner with some lawyer/law firm to make the whole process of having a visa even simpler;

\- In the section "Jobs with a visa" I would like to have a filter no just for country but also on the type of job (at the least by sector).

<comment><AUTHOR> Thank you, this is noted. Very helpful. Other users are also requesting such a filter, and it should be simple to make it happen. I appreciate the suggestions!

</comment></comment><comment><USER3> This is really great! It can be very difficult and confusing looking for this type of information on .gov sites.

<comment><AUTHOR> Creator here, thank you! That's the main issue for sure, especially when someone is flexible with the destination. Once I'm able to have most countries, I think that's going to be the strongest part of the website. But right now, most visitors are coming for the list of jobs with visa sponsorship.</comment></comment>


Ask HN: As you scale, how do you promote autonomy without courting chaos? - <AUTHOR> And how do you standardize without risking stagnation and apathy?
I imagine that the natural inclination of a company towards scaling is to _standardize everything_
I was surprised to read from a former engineer at Spotify[1] that Spotify (at least used to) use iframes to separate features that were sometimes on the same page so that squads could preserve their autonomy in which tools to use
A few surprising excerpts:
> It's important that squads are able to control their own reality and can pick the best solution for their problem domain, instead of having a company tool forced down their throats just because it's in-house.
> The desktop client UI [is built] out of many small, self-contained web apps called Spotlets. They all run inside Chromium Embedded Framework, each app living within their own little iframe, which gives squads the ability to work with whatever frameworks they need, without the need to coordinate tooling and dependencies with other squads. While this approach has the disadvantage that we have many duplicate instances of different versions of libraries, increasing the size of the app, but it offers the massive advantage that introducing a library is a discussion between a few people instead of decision that involves ~100 people and their various needs. Not only would such a big discussion extremely time-consuming and hard, it would also force us to use a least-common-denominator approach to picking libraries, instead of picking the ones specifically tailored to the problem domain of each squad.
This seems at once both sensible and insane
I wonder what the discussions would have been like to have had them arrive at this approach, and whether they still do this.
More importantly though, how have other companies tried to solve this problem?
[1]: https://www.quora.com/How-is-JavaScript-used-within-the-Spotify-desktop-application-Is-it-packaged-up-and-run-locally-only-retrieving-the-assets-as-and-when-needed-What-JavaScript-VM-is-used <comment><USER2> We have a similar approach at JotForm. 5 small cross-functional product teams work pretty autonomously. They can use the libraries and tools they prefer. Things happen like how fish or birds decide where to go. There is sometimes chaos but once someone finds something good and starts leading others, one by one everyone starts using that idea, technology or tool. Decisions are more likely to be from bottom as oppose to top down this way.

How about what to work on? The biggest problem can be focus. We found an approach that works well. Every year, our user researchers interview customers to find the biggest constraint (ToC) in our product. Then we ask these teams to attack that constraint for a year.</comment>


FCC Grants Approval of AT&T-DirecTV Transaction [pdf] - <AUTHOR> https://apps.fcc.gov/edocs_public/attachmatch/DOC-334561A1.pdf

<comment><USER2> "The conditions imposed by the Commission address potential harms presented by the combination of AT&T, one of the nation's largest telephone and Internet service providers, and DIRECTV, the nation's largest satellite video provider...These targeted conditions, which generally will remain in effect for four years after the merger closes"

So the commission admits that there are potential harms of merging two large firms, but will only keep the conditions that prevent these harms from happening for only 4 years.

Why would the commission see the potential harm of combining these two large enterprises and yet have time bound conditions like Non-Discriminatory Usage- Based Practices, Discounted Broadband Services for Low-Income Subscribers and Internet Interconnection Disclosure Requirements around for only 4 years?

<comment><USER3> AT&T is only interested in DirecTV because AT&T's DSL services don't have enough bandwidth to carry simultaneous TV and Internet service. The DirecTV acquisition is a stopgap until AT&T can catch up to DOCSIS/Fiber networks, at which point satellite TV will be mostly dead regardless of whether AT&T buys them or not. If the conditions and restrictions work as intended, then by the end of the four year period AT&T will be on a more level playing field with the cable companies and their conflicts of interest should be managed through industry-wide regulations.

<comment><USER4> It's hard to believe that AT&T has any serious intention of improving their network.

If they wanted to spend $50 billion they could run optic fiber to 50 million houses at $1000 a house, then they would have a competitive network in every way.

<comment><USER5> My boss told me something interesting the other day. AT&T has been around for a hundred years, and they have ran a lot of copper wire over those years. They also hired a lot of linemen to maintain the copper wire, and they eventually formed unions of workmen that maintain copper wire. AT&T is interested in rolling out fiber for several reasons, but one of which is that they get cheaper labor because they bypass the union. The union contracts are written in terms of copper wire, they say nothing about fiber optic, so the annoying unions can be ignored.

Also, AT&T has been pretty good about rolling out fiber to businesses at least. I can thing of several older buildings with numerous T1 circuits and plenty of pots lines, yet AT&T still added fiber. Every brand new building that I've been in is served by fiber, for internet, phones (pri trunking), or a data connection to another campus. There are only a couple of pots lines for backup. They might not be too interested right now about running fiber to residentials, but they are very interested in running fiber to businesses. It's possible that it's simply not profitable enough right now, but I can't think of any reasons why the technology won't trickle down eventually.

Source: I work as a subcontractor of a subcontractor of AT&T, basically installing Cisco routers and equipment in businesses.

</comment></comment></comment></comment><comment><USER6> I wonder what the AT&T unlimited TV package will look like. I assume it will be limited to 10 hrs of TV a month, and then once you go over you only get commercials.

<comment><USER7> You're being too harsh. They'll probably just downgrade from HD/16:9 to SD/4:3 after you've exceeded your 10 hour limit. And you will always have the option to rollover hours you didn't watch last month!

</comment></comment><comment><USER8> they are getting closer to their final form.

let them keep wasting their profits on old business models, their well will dry up soon enough.

<comment><USER9> How did the model work for for recording artists?

MP3 killed the CD and Apple replaced MTV. Now the artists don't make as much money.

<comment><USER10> And I'm sure Taylor Swift was so sad that evil spotify was stealing all of her due profits, so she pulled her songs from their service.

The whole industry is garbage, for both successful and indie artists.

<comment><USER11> Perhaps that's a good thing. I look at the content market wrt. movies and music and see a thing that would be better off not existing, leaving the field for those who do work for the love of their craft.

<comment><USER12> > leaving the field for those who do work for the love of their craft.

In their free time, after their accounting gig?

</comment></comment></comment></comment></comment><comment><USER13> Time for me to cancel my DirectTV

<comment><USER9> I'm waiting for Apple to acquire a common carrier.

<comment><USER12> Seriously?</comment></comment></comment>


Ask HN: What do you use for CRM / Marketing Automation? - <AUTHOR>

We're heavily leaning towards Salesforce as our "one version of the truth" - fed app usage data by us, integrated with Zendesk for support, and Chargely for billing.
Anyone have suggestions, comments, etc? Particularly around Marketing Automation systems. Hubspot looks amazing but is laughably expensive.
Any insight is much appreciated. <comment><USER2> I may be heavily biased here. But did you consider agilecrm.com - we offer marketing automation, web analytics, contact management with lot of built-in widgets and support for custom ones, javascript API to create contact and tag them to initiate campaigns for onboarding, 2-way emails, social suite (like hootsuite) but you can import your prospects into crm and nurture them, real- time alerts, scoring of leads etc.

[http://www.agilecrm.com](http://www.agilecrm.com)

If you are looking for something specific for SaaS, we have a new vertical offering which offers all these but lot more metrics such as CAC, LTV, on boarding popups to guide them based on the user's activity, cohorts, revenue forecasting etc.

Give us a haul!</comment>


Use RF noise from VGA DAC to drive VHF TV - <AUTHOR> http://bellard.org/dvbt/ <comment><USER3> I remember reading articles in the 90's about the TEMPEST technology (or some other name) where spy agencies could remotely eavesdrop on the output of your computer monitor, without a line of sight, from a truck parked on the street.

Example: [http://www.sans.org/reading- room/whitepapers/privacy/introdu...](http://www.sans.org/reading- room/whitepapers/privacy/introduction-tempest-981)

<comment><USER4> The general term for this (although a different concept to TFA) is [http://en.wikipedia.org/wiki/Van_Eck_phreaking](http://en.wikipedia.org/wiki/Van_Eck_phreaking) (as popularized in Cryptonomicon)

</comment></comment><comment><USER5> I have a really cool story that I like to tell whenever something like this comes up. When I was a kid we had a very old 386 PC with a gigantic black & white CRT monitor, it was also _very_ heavy (at least for a little kid). The computer was in a room adjacent to the living room where we had the TV and one day we started noticing lines of snowy noise appearing on the image on the TV. It seemed to be random and it was annoying as heck. One day I'm sitting on the computer doing something in good old MS DOS and the door is open, so I can work on the PC _and_ watch cartoons at the same time, so double win for me!! It is then that I notice something really curious, the lines of noise on the TV are identical in shape and pattern to the ones on my monitor!!! Whoa!! I try writing long lines alternating with short ones and they also appear on the TV, and even though you couldn't discern specific letters you could definitely tell the spacing between the words. Mind blown!!! I think the culprit was in the unshielded cable running from the antenna in our roof to the TV, which happened to pass by the room with the computer in it. Anyway, I solved the noise "mystery" that day, but was subsequently banned from using the computer whenever the family was gathered watching TV. Talk about being ungrateful :)

</comment><comment><USER6> On a similar note, the Raspberry Pi can be turned into a FM transmitter without additional hardware [0]. I remembered seeing another hack for a higher frequency that required a filter to be attached to the GPIO but I can't find the link.

[0] [http://www.icrobotics.co.uk/wiki/index.php/Turning_the_Raspb...](http://www.icrobotics.co.uk/wiki/index.php/Turning_the_Raspberry_Pi_Into_an_FM_Transmitter)

</comment><comment><USER7> There is an even better story about reading the screens of people using VGA cards at a distance by post processing the emissions coming from them [1]. Of course it is always fun to have your computer do things in interesting an unexpected ways.

[1] [http://www.eskimo.com/~joelm/tempest.html](http://www.eskimo.com/~joelm/tempest.html) used to be a page that had links to code that was used for reconstructing a vga image on your screen from picking up passive radiation, it has sadly gone away.

<comment><USER8> I think [http://www.jammed.com/~jwa/tempest.html](http://www.jammed.com/~jwa/tempest.html) might be the same FAQ/info page (right author, anyway), although last updated in '99, and no obvious links to any code (except one link about sniffing CPU emissions, which is also bitrotted)

<comment><USER9> Playing music using monitor emissions: [http://www.erikyyy.de/tempest/](http://www.erikyyy.de/tempest/)

<comment><USER10> See also the Braun Tube Jazz Ensemble [http://youtu.be/Ouue59iY0Hs](http://youtu.be/Ouue59iY0Hs)

<comment><USER11> This is interesting. I wish I understood what was going on. YouTube's automatic translated captions were little help.

<comment><USER10> He has guitar leads on his hands, and preset loops playing on each tv - <USER2> example, drum samples, tones - recorded on VHS. The audio is recorded as the video signal. Then, by putting his hands near the front of a television, the video signal is picked up by the guitar lead and played through the amplifier. He can play it by selecting which sample to play when.

Another video of him playing: [http://www.youtube.com/watch?v=v5T2Q_wgoKg](http://www.youtube.com/watch?v=v5T2Q_wgoKg)

And a video of his other project, Open Reel Ensemble: [http://www.youtube.com/watch?v=AFM8UarAuVw](http://www.youtube.com/watch?v=AFM8UarAuVw)

</comment></comment></comment></comment></comment></comment><comment><USER12> This guy never ceases to amaze.

Allez Fabrice!

</comment><comment><USER13> Fabrice Bellard, what a tease. Lots of awesome engineering work, no source code =(.

<comment><USER14> Well, not entirely fair. QEmu is open source.

</comment></comment><comment><USER15> Music played on a radio made from the RF emissions of the IBM 1401:

[http://youtu.be/EPk8MVEmiTI](http://youtu.be/EPk8MVEmiTI)

</comment><comment><USER16> Guys, this is some of the coolest stuff I've ever seen. _These_ are the articles that keep me coming back to Hacker News.

</comment><comment><USER11> Take a look at the .pgm images that generate those RF signals. I imagine that's the best we could hope to see leaking from some interstellar civilization's communications.</comment>


3 Things a Founder Can't Tell their Team - <AUTHOR> http://www.gobignetwork.com/wil/2007/6/18/3-things-a-founder-cant-tell-their-team/10167/view.aspx <comment><USER2> Pretty poorly phrased. The tips are good, but it took me a few passes to figure out what was meant. The title conveys the meaning to be: "You can't tell your team to 'leave it at home', 'always complain up, not down', or 'no gossip, ever'", when in fact those are the things you should be telling them.

<comment><USER3> The things you should tell them?

I took it as a list of things you should be doing as the leader of the company.

</comment></comment><comment><USER4> I tried to be pretty specific in the title by using "The Founder"

<comment><USER2> Right.. it's implying the founder can't say "leave your personal life at home", when he actually should. Ehh, it was just a quibble.. one can figure out the meaning by reading it more intimately.</comment></comment>


Show HN: What's in My Picture V2.0 – Find out what's in your picture - <AUTHOR> https://www.whatsinmypic.com <comment><AUTHOR> Hi All,

What's In My Picture is a way for people to gain insight on what their images contain without seeing them. It allows people to detect human pose key points, face orientation and eye gaze direction, objects, nudity, text, celebrities, landmarks, age, gender, emotions, and captions their image. It also provides a feedback functionality to measure the level of success of each image processed in order to do further improvements to the results.

Check out the update and let me know what you think.

Thanks, et_codes

</comment><comment><USER2> That's cool. Nice job, keep it coming.

</comment><comment><USER3> This is pretty slick AI.</comment>


Ask HN: Break my Go chat app, please - <AUTHOR> Made a small chat program in Go. Looking for maybe a couple people to take a poke at it and maybe find bugs.
Can reach it here: wiby.me/chat
The source can also be looked at from there. The idea is to make it work on pretty much any browser on any system from the last 30 years, and fit on a 9" mac. Anyhow, I am looking for some free labor to test it out.
Thank you in advance. <comment><USER2> It's inefficient to read the list of swear words every time _swearfilter_ is called (and similarly for _checkban_ and _checkAdminIP_ )

The way it is implemented, you'll also have quite a few false positives ([https://en.wikipedia.org/wiki/Scunthorpe_problem](https://en.wikipedia.org/wiki/Scunthorpe_problem))

Also, is it common idiom in Go to both _defer f.Close()_ and manually call _f.Close()_? Seems noisy to me (and would, in many other systems, give an error when the deferred code tries to close an already closed file)

Other issue: from glancing at the code, the 403 page doesn't seem to return a 403 status code.

<comment><AUTHOR> >It's inefficient to read the list of swear words every time swearfilter is called (and similarly for checkban and checkAdminIP)

Agreed, its not efficient.

>The way it is implemented, you'll also have quite a few false positives

Yes. The filter is only for a handful of swearwords, I wouldn't bother making it larger since people can easily circumvent it with various characters.

>Also, is it common idiom in Go to both defer f.Close() and manually call f.Close()? Seems noisy to me (and would, in many other systems, give an error when the deferred code tries to close an already closed file)

Honestly, I don't know. This was just based on some file io tutorials I referenced. Might be able to not have that defer statement at all. I haven't tried.

>Other issue: from glancing at the code, the 403 page doesn't seem to return a 403 status code.

Good catch.

<comment><USER2> _"Yes. The filter is only for a handful of swearwords, I wouldn 't bother making it larger since people can easily circumvent it with various characters."_

That's not the problem I mentioned. _False positive_ means cases where your filter thinks it sees a swear word, while there is none. Cases where there are swear words that the code doesn't detect are false negatives.

 _"Might be able to not have that defer statement at all"_

That wouldn't be robust. _defer_ guarantees the file gets closed, no matter how the function is exited. That's what you want (almost all the time). It's the _close_ just before returning that's superfluous.</comment></comment></comment>


Show HN: filter "Ask HN: Who is hiring?" jobs by city - <AUTHOR>

Hi fellow job seekers!
In a few hours this month's "Ask HN: Who is hiring?" thread will be posted. I've created a simple bookmarklet that removes jobs from the cities you are not interested in.
You can find the bookmarklet & instructions here: https://github.com/janhancic/hnHiringFilter
I hope somebody will find it helpful. <comment><AUTHOR> Clickable link: <https://github.com/janhancic/hnHiringFilter></comment>


At Vice, Cutting-Edge Media and Allegations of Old-School Sexual Harassment - <AUTHOR> https://www.nytimes.com/2017/12/23/business/media/vice-sexual-harassment.html <comment><USER2> I'd heard rumors about this at Vice. Glad to see it getting some air.

Stories like this are important, because I think the traditional view of sexual harassment is that it happens at JP Morgan, or Exxon, or "stodgy" old companies.

People don't think that it can happen at their cool, hip workplace where everyone's woke. But, power is power.

Incidentally, and totally based off of a gut reaction and not data: I wonder if this is the death knell of "company outings." More and more it feels like people are content to let work be work, and avoiding things like holiday parties and after-work gatherings.

I wonder if it's partially because of situations like this: You might be inappropriately propositioned. Or, you might have too much to drink and make an inappropriate advance - I don't even mean anything grossly egregious here necessarily, but a superior making an advance on their subordinate is pretty inappropriate even if the advance itself is tame.

<comment><USER3> I think, in general, that it is totally fine to have company outings, but propositions of any sort should be avoided. You're certainly asking each individual to have self discipline, but in my mind this is a very reasonable expectation.

As a rule, everyone should probably avoid relationships at work. If you do decide to have a relationship, do it right and start extremely slowly (i.e. coffee shop date, etc). Feel things out, not up :) and make sure that both people have the same ideas before moving to the next level. Relationships between superiors and subordinates should generally be forbidden.

<comment><USER4> On the other hand, think about how much time you spend at work. How close your interactions are with others. We - human beings - are jammed into little 4-walled boxes for the majority of our days with a bunch of people we already have something huge in common with...and told not to get too close with them. It's pretty wild, the whole scenario.

<comment><USER5> As a married guy I find this line of thinking hard to understand. "How are we supposed to work so closely with these people without getting 'too close?'" Uh, I'm not allowed to solicit a date in any context: work, the grocery store, cafes, etc. Somehow I manage, and so do most married people.

<comment> xkcd-sucks As a married guy, if your marriage is truly fulfilling, this problem is irrelevant to you.

Given that proximity is the single largest determining factor in romantic partnership, if you work the majority of your time then coworkers will be your most promising dating pool. If you don't work much, you're probably stressed from unemployment. The number of people that have free time to enjoy close proximity with non-coworkers is certainly a minority.

</comment></comment></comment></comment></comment><comment><USER6> Related story from last month: [https://www.thedailybeast.com/unsafe-and-just- plain-dirty-wo...](https://www.thedailybeast.com/unsafe-and-just-plain-dirty- women-accuse-vice-of-toxic-sexual-harassment-culture)

One of the interesting parts to come out of that (and from the OP) is VICE's "non-traditional workplace agreement":

> _New hires at Vice also sign a "Non-Traditional Workplace Agreement," an > infamous internal document that requires employees with no experience at > Vice to agree as a condition of employment to not be generally offended by > anything that goes on there._

[https://www.documentcloud.org/documents/4203989-Non- Traditio...](https://www.documentcloud.org/documents/4203989-Non-Traditional- Workplace-Agreement.html)

<comment><USER7> > to not be generally offended by anything that goes on there.

Is it a one way or two way street at Vice - ie. are you allowed to "offend" in your turn too?

<comment><USER8> Seems pretty one way:

> One woman said she was riding a Ferris wheel at Coney Island after a company > event when a co-worker suddenly took her hand and put it on his crotch.

So basically the letter the women sign is a license for certain men in a elevated position to assault women.

I feel like this kind of shit puts us two steps back, especially when the American president is accused of similar behavior towards woman, now it will give that side another "whatboutism" ammunition.

I have a strong nagging feeling that there are bound to be more #metoo stories shortly from Vice.

I mean it's so fucking bizarre to have a systematic infrastructure set in place to allow it's higher up members to traumatize defenseless women.

If the mainstream media wanted to destroy Vice once and for all, now seems like an appropriate opportunity.

<comment><USER9> > If the mainstream media wanted to destroy Vice once and for all, now seems > like an appropriate opportunity.

So I guess its well accepted now that "mainstream media" is not merely there to report what is going on but have active agendas to shape the world according to their wishes. It a weapon of destruction.

<comment><USER10> > So I guess its well accepted now that "mainstream media" is not merely there > to report what is going on but have active agendas to shape the world > according to their wishes. It a weapon of destruction.

I'm not sure what you're angling for, but they're all corporations with market interests. The NYT itsself authored the article.

Your comment appears to be reaching pretty hard to throw in that MSM comment.

<comment><USER11> Wat? That was a quote of parent. Besides, Vice would have to try pretty hard to get more mainstream than it already is. Is TFA _not_ discussing Matt-Lauer- style remote-kidnapping locks?

</comment></comment></comment></comment></comment></comment><comment><USER12> Straight from 2004:

[https://www.vice.com/en_us/article/av759j/the- vice-v11n5](https://www.vice.com/en_us/article/av759j/the-vice-v11n5)

"The VICE Guide to Partying

Here are some of the types you'll need to invite.

TRANSSEXUAL: Pre-op is good, but post–breast implants, pre–gender reassignment is PERFECTION. All transsexuals are slutty, so don't worry about that. This guest is a very high priority and should be catered to accordingly. Put her first in the queue for cocaine and drinks. Tell her how pretty she is. Touch her a lot.

GUY WHO WILL FUCK TRANSSEXUAL: He is your #2 guy, your party wingman. If the tranny doesn't feel loved, she will leave. Then you're fucked. If you don't have a tranny chaser in your six-degrees network, I have one word for you: craigslist.com. We posted there for this party ("Guy wanted to fuck tranny in ass") and had 20 respondents within an hour. I picked this particular man because he has the biggest ring through his cockhead that I have ever seen.

WANTON DRUNK SLUT: This is a surprisingly tough one to find. Once you get a reliable drunk slut in your life, someone who will shed her clothes and let a room full of people write on her with indelible markers at the drop of a hat, hold onto her like a dinghy in the perfect storm. She is a true party staple and will prove again and again the fact that nudity at a party is as contagious as the bird flu. Just as the night begins, give her (and only her) a handful of shrooms."

Yep, that's Vice. The current progressive, cutting-edge image is just makeup.

<comment><USER13> Wow, that article only gets worse. It's actually weird that one of the takeaways of the top-level article is that people were surprised to find sexual harassment/assault at a "young, hip" company like Vice. But looking at this kind of content one has to expect it to be _much_ worse at Vice than at "traditional, old-school" companies.

</comment></comment><comment><USER14> > In 2003 Vice reached a $25,000 settlement with the freelance writer Jessica > Hopper. The deal involved defamation claims tied to an interview she did > with the rapper Murs that was published in the February 2003 issue of the > magazine, according to a copy of the agreement viewed by The Times. During > the interview, Murs asked Ms. Hopper if he could have sex with her. She said > no and included that answer in her article.

> But before the article was published, the magazine changed her response to > yes and printed it under the headline, "I Got Laid But Murs Didn't."

> Mortified, Ms. Hopper hired lawyers. The two sides struck a settlement that, > in addition to a payout, required Vice to print a retraction and a formal > apology.

Wow. I feel so poorly for Ms. Hopper. They defamed her and shamed her, yet a $25,000 settlement likely only paid for her lawyers. Disgusting -- they should feel ashamed.

<comment><USER8> I hope that she can get the appropriate justice. $25,000 is a pittance compared to the psychological trauma from having to relive the trauma over and over from being discussed. I mean, fuck man, why even become a lawyer if you are going to achieve such poor results?

But I guess when you can't afford the same lawyers a large corporation can, its going to be an uphill battle. Especially now when the US courts is trending towards less class action lawsuits.

When all goes wrong you are supposed to be able to count on the law. Seems like a pretty big asterisk is needed there.

<comment><USER15> humiliation surely, but 'trauma' sounds like a truly extreme stretch

</comment></comment></comment><comment><USER16> > One woman said she was riding a Ferris wheel at Coney Island after a company > event when a co-worker suddenly took her hand and put it on his crotch.

I have absolutely no idea why someone would think this is OK to do. Generally I can try to piece together how someone might rationalize their behavior but the best I can come up with on this one is: alcohol.

<comment><USER17> That incident happened after a company event, isn't that considered private time? I mean, she would have had to agree to go with the co-worker, during their off-hours, in the first place and he might have interpreted her willingness to go along as a signal of mutual interest (romantic, sexual) in each other?

That isn't meant as an excuse for such creepy, if not straight up criminal, behavior. But as somebody with some social issues of his own, I can relate quite a bit with not being able to properly interpret social and body cues.

To me, the vast majority of people are walking blackboxes where I have no clue how they would react to most actions of my own. Which boils down to me acting rather passively in most social situations out of fear I might break some unspoken rule, misinterpret the current mood in the room/between people.

<comment><USER18> If a woman wants to touch you, she will. End of story.

<comment><USER19> Wouldn't that be assault as well?

<comment><USER20> Yes.

</comment></comment></comment></comment></comment><comment><USER21> I recall an episode about Lady Boys in Thailand, where at the end Shane signs off by essentially says he's going to have sex with a male prostitute.

That seemed more "wrong crowd" than just "edgy" to me.

</comment><comment><USER8> The co-founder of Vice started a alt-right white boy club[1], which was pretty shocking to be honest. It did make me stop watching Vice & Vice News altogether.

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

<comment><USER22> McInnes is a racist, misogynistic shitheel for sure, but he also left in 2008. Since, Vice has become an outlet that does objectively good stuff with its reporting and its specialist media--I love Waypoint, I have a friend there whose moral compass is beyond reproach as far as I am concerned, and I have zero doubt that that friend wouldn't be there if they weren't convinced of the place.

Near as I can tell, Vice is an outlet that escaped its asshole founder and gone past his goals. Should probably be commended for that (while at the same time expected to clean house when confronted with meritorious allegations).

<comment><USER23> Not sure why you're being downvoted.

Austin Walker (current editor in chief for Waypoint - Vice's Video Games site) is the walking antithesis of an alt-right bro.

It is a good question though: how long do you hold an organization responsible for someone or for their collective actions?

<comment><USER24> > Austin Walker (current editor in chief for Waypoint - Vice's Video Games > site) is the walking antithesis of an alt-right bro.

What does being left wing or right wing have to do with anything? We're talking about sexual harassment, not politics. The majority if the recent high profile cases have been democrats doing the harassment btw.

<comment><USER25> Read two posts above you. We were talking about how one of the founders is a public racist, but how Vice's current editorial approach seems to have move passed that.

I don't think it's controversial that sexual misconduct is persistent across the political spectrum.

<comment><USER24> Yes, Vice is extremely left wing. They apparently also commit a good deal of sexual harassment internally if this article is to be believed.

Not sure what the founder who left (and his politics) well before any of the alleged offenses has to do with anything.

</comment></comment></comment></comment></comment></comment><comment><USER26> I am baffled by the outrage. Isn't Vice known to be an edgy, drugy and boundary bending outlet? Are we seriously pretending to be suprised that drugged up late teens are doing sick stuff. Or what am I missing here?

<comment><USER27> just because d-bag is your "image" doesn't make you immune from sexual harassment laws.

<comment><USER26> I am not criticizing the laws. What I have issues with is the fake outrage. It seems so hypocritical to me acting suprised about this situation. For me it is on the same level than breaking the news that rock stars are taking drugs and having sex with girls half their age. Sure, it is illegal and for some morally problematic, but pretending this is a scandal is beyond ridiculous.

</comment></comment></comment><comment><USER28> Yesterday's "The Vice Guide to Right Now" podcast was about sexual harassment in the restaurant industry[1]

Hypocrites.

[1] [https://www.vice.com/en_us/article/59w3q3/sexual- harassment-...](https://www.vice.com/en_us/article/59w3q3/sexual-harassment- in-the-food-industry)

<comment><USER29> Vice has different people saying and doing different things. It's not a monolithic entity. I'm not sure what might've given you the impression that is.

<comment><USER28> The entity is vice.com, not Viceland the cable channel, not Vice Magazine, not Vice News or Vice Films but vice.com the website.

Now look at how many articles on sexual harassment vice.com the website has published recently:

[https://www.vice.com/en_us/topic/sexual- harassment](https://www.vice.com/en_us/topic/sexual-harassment)

And yes someone has editorial control of vice.com.

</comment></comment></comment><comment><USER30> I dont think these expose's and #metoo campaigns are going to have the effect that they are going for. These things are merely exposing consequences (or lack thereof)

I think it is more likely that gender exclusive clubs will become more in vogue again, where they simply bus in the people willing to be objectified

Unfortunately There is nothing about this that is curbing behavior or desires, it is only showing the folly of gender diversity in the workplace. The additional liability incurred

Im not endorsing these observations, I and almost everyone will publicly say this is wrong, upvote how heinous people in power can be, but what I perceive of peoples desires are unchanged.

<comment><USER31> I'll bite even though I shouldn't. What do you mean by the "folly of gender diversity in the workplace?"

<comment><USER30> The additional liability incurred, as I wrote</comment></comment></comment>