My name still causes SQL errors - <AUTHOR> https://twitter.com/gintveld/status/730317679886794752 <comment><USER2> I know this too well. Some pages will tell me that my name or address is 'invalid' because it contains spaces or forbidden characters.

I'm sorry, but 'ñ', apostrophes and accent marks are not forbidden, and no name should be ever 'invalid'. How can a name even be 'invalid'? Sometimes I think too many sites assume (wrongly) that all customers will be an average english-speaking, US-resident person.

<comment><USER3> Sites don't (or at least shouldn't) have any obligation to serve everyone. Most people are content to render their name in plain ASCII. How much extra are you willing to pay to be able to use those symbols? Or do you expect everyone else to subsidize you?

<comment><USER4> Certainly, most websites have no obligation to serve me as a customer, but if they tell me that my name is "invalid", they shouldn't be surprised if I take my custom to a competitor who isn't quite so rude.

But you seem to be missing the fact that "Gijs in 't Veld" is perfectly valid Ascii, as would be names like "O'Leary" or "O'Reilly" that are perhaps more common in the English-speaking world.

<comment><USER5> And some websites, such as government portals to various departments and services, _do_ have implicit (and often even explicit) obligations to serve everyone.

I wonder how well GP would take it if, say, the IRS webpay or DMV sites (or their equivalent wherever GP happens to live) balked at their name.

<comment><USER4> Yes, government services was what I thought of when I wrote " _most_ websites". Then again, I feel like those tend to be the worst user experience offenders (which is what this comes down to). It took me several attempts to mangle my home address into something the US visa application form would accept and I've seen _ö_ turned into _ö_ on my own country's official websites so many times that I can remember the mojibake.

I wonder why that is. I guess part of the reason is that government doesn't need to invest heavily in UX because there is no threat of people going elsewhere – when you need a passport, you need a passport, and you're not going to order one from Amazon. In fact, there's probably a disincentive for government to continuously improve their UX precisely because any changes to a system that's in place and working well enough only cost them money.

Are there any counterexamples of government websites that offer good user experience?

<comment><USER6> The tax e-filing system in Massachusetts is a government website that offers a quite good user experience. It could be a bit better (e.g. it could save your general W-2 info from year to year on the assumption that you probably didn't change employers), but it's fairly nice in most ways; the W-2 thing is the only problem I've run into with it, and it has a fairly clear UI. Especially given the complexity of the actual paper MA tax forms.

On the other hand, the MA website where you pay things like unemployment insurance for your employees is terrible, complete with being offline outside of normal business hours (because afaict they take it offline while they do batch imports from physical media that companies send them). Note that this is not as much of a "voter-facing" website, of course. ;)

</comment></comment></comment></comment></comment></comment><comment><USER7> I wonder how everyone in the original thread comments is still falling for this infamous "sanitize input!" trap.

If "the input" is sanitized, poor guy would be left without an apostrophe in his name, and rightfully pissed off.

Prepared statements are the only way to do it.

<comment><USER8> I agree that prepared statements are much better than sanitising inputs, but surely a sanitised version of his name would be _Gijs in \ 't Veld_ Leaving the apostrophe in tact

<comment><USER9> That would be silly, then the backslash will be shown everywhere.

<comment><USER10> I can't tell if you're trolling or not, but this is not how string escaping works in SQL or any other programming language that I know.

        >> SELECT 'here is an apostrophe: \'';
        >> returns: here is an apostrophe: '

The backslash is not part of the string but just a hint to the compiler. The literal string '\'' represents a one byte (if ASCII) string containing only a single apostrophe character.

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

<comment><USER11> There's a difference between saying that

        Gijs in \'t Veld

is a 'sanitized' version of

       Gijs in 't Veld

and saying that

       'Gijs in \'t Veld'

is a SQL String literal representing the string

       Gijs in 't Veld

</comment></comment></comment></comment></comment><comment><USER12> Aside of the obvious SQL injection (heck - the way this is set up, it obviously even takes multiple queries in one string - this is pure heaven from an injection standpoint), I'm also wondering what kind of schema this is?

Creating an user as a sequence of operations? Why?

Imagine the ways this data can get corrupted? What if for some reason only one of the queries executes? What if somebody removes one of the rows for a user but not the other when doing support or maintenance?

<comment><USER13> In a past life, I converted an intranet application for some government department from Oracle/Coldfusion.

The whole application, every SQL query taking input, was vulnerable to SQL injection.

For many insert operations, I'd find a pattern appearing of first inserting a row with some random value in one of the columns (`temp_key`), then performing a select based on this key to get the row back to know the primary key, and then continue to update other fields in the same row, and adding other records to other tables referencing this primary key.

Obviously, transactions was a foreign concept to the original developers. I still remember taking a deep breath once I found a code snippet that would try an insert again if the insert failed because the randomly generated `temp_key` was already used before, a problem that seemed to really start bothering them as the database grew larger...

<comment><USER14> I'm stretching my memory as a "full stack" dev back in the 90s but I seem to recall that CF couldn't do transactions for its first few versions. People were begging for <cftransaction> to become a thing. I also don't remember being able to call an oracle stored procedure from CF in version 1 or 2.. But I'm hazy on that for some reason I remember the ODBC driver not supporting it. As a result I recall resorting to hacky stuff like what you describe. It wouldn't surprise me in the least if there is government cfml code out there from the 90's. It was a challenging time with far fewer tools.

</comment></comment></comment><comment><USER15> That reminds me of the approach taken by many contact forms for members of the US congress. I believe the vendors have to follow certain security processes which includes sending the user to a 404 page if certain malicious attempts are detected. The end result in many cases is that there is a list of words that can not be submitted successfully through their form that changes over time and just check in certain fields based apparently on however the vendor wants to implement the security measure. Is your name Walter? Sorry but you sound like a sql injection attack so we will redirect you and the message you just spent an hour on over to a 404 page.

</comment><comment><USER16> Very related: [http://www.kalzumeus.com/2010/06/17/falsehoods- programmers-b...](http://www.kalzumeus.com/2010/06/17/falsehoods-programmers- believe-about-names/)

<comment><USER17> I understand what you are saying but this has nothing to do with names but with SQL injections, escaping and prepared statements (the lack of).

<comment><USER11> It has everything to do with names. Among the things that programmers sometimes believe about names, as in this case, is _that when you stick apostrophes around them they are always a valid SQL string literal_.

<comment><USER18> Inexperienced programmers naively believe that about all string input, so the fact they believe it about names isn't particularly interesting.

</comment></comment></comment></comment><comment><USER19> Prepared statements are actually worse than escaping in Postgres because prepared statements can sometimes use the wrong query plan. Refer to the documentation:

> In some situations, the query plan produced for a prepared statement will be > inferior to the query plan that would have been chosen if the statement had > been submitted and executed normally. This is because when the statement is > planned and the planner attempts to determine the optimal query plan, the > actual values of any parameters specified in the statement are unavailable. > PostgreSQL collects statistics on the distribution of data in the table, and > can use constant values in a statement to make guesses about the likely > result of executing the statement. Since this data is unavailable when > planning prepared statements with parameters, the chosen plan might be > suboptimal.

Sometimes this can be more than "suboptimal" but actually an entirely different index and orders of magnitude worse performance.

</comment><comment><USER20> This guy isn't just a tester, he's the test data.

</comment><comment><USER21> Prepared statements are hard. They've only been around for decades.

</comment><comment><USER22> Good ole Little Bobby Tables [https://xkcd.com/327/](https://xkcd.com/327/)

<comment><USER23> I feel like that joke is so widely known that it can be retired, or at least, referenced without needing the link.</comment></comment>


How to use EC2 on-demand with Jenkins? - <AUTHOR> https://www.atlantbh.com/using-ec2-on-demand-with-jenkins/ <comment><USER2> The correct term is spot instance. On-demand would be a normal instance because it launches immediately but is more expensive.</comment>


Ask HN: How to switch to embedded software development mid-career? - <AUTHOR> I'm a software engineer with 15 years experience. I've worked on various types of software, but always within the realm of "traditional software", like web servers, desktop software, and lately, services.
Ever since switching to services, I've been disillusioned with the field. I don't like messing with AWS, hate dealing with Kubernetes and the ecosystem around it, and I just feel like the field as a whole produces sloppy code.
I feel constantly anxious about having to learn new stacks often, usually having little time to do so. I can't master anything. I fail to see how all the stuff that pops up moves things in a better direction. It feels more like randomization than improvement.
Over the years, I've caught little anecdotes about embedded software development, in particular mission critical software. Maybe I'm wrong, but it seems to be a more rigorous field when it comes to writing software that works and is verifiably correct. I also like the idea of writing code that runs on a single machine, as opposed to e.g. a Kubernetes cluster.
For example, someone wrote this here on HN:
> The embedded world is very slow to change, so you can read about "modern approaches" (i.e. approaches used today) in any book about embedded programming written in the last 30 years.
> I currently work on spacecraft flight software and the only real advance on this project over something like the space shuttle that I can point to is that we're trying out some continuous integration on this project. We would like to use a lot of modern C++ features, but the compiler for our flight hardware platform is GCC 4.1 (upgrading to GCC 4.3 soon if we're lucky).
https://news.ycombinator.com/item?id=22391560
That sounds like a dream to me. To be able to focus my expertise on one thing (or one set of things) and apply that throughout my career.
Is it possible for someone at my career stage to switch into embedded software development? Has anyone here done that? <comment><USER2> The grass is always greener. I've been doing embedded for 13 years and it's not peachy. You use C mostly, or C++ that looks like C. You write bootloaders and same drivers over and over. There's constant diagnostics and same arguments - is it SW issue or HW issue? How can we work around HW issue with SW patch? Embedded development is more about engineering than about software development. Memory and space constraints are harder, shipping errors is so much more expensive and you spend about 50% of time in datasheets and schematics.

I see no reason why you couldn't make the switch. It is I think less lucrative than some other branches, and far fewer people apply for embedded position. As long as you demonstrate that you are reliable and interested, you should have no problem getting the position with no previous experience. Of course, this depends on your location. There are far less job offers for remote work, and it would complicate the learning process.</comment>


Using too much water to wash your clothes releases more plastic microfibres - <AUTHOR> https://www.abc.net.au/news/2019-09-26/delicate-washing-cycle-releases-microplastics/11551356 <comment><USER2> I think we are past prevention at this point and need to figure out ways to adapt/clean up that can be easily and economically implemented.

<comment><USER3> Note that cotton clothes leave exactly 0 microplastics no matter how much water is used to wash them. Prevention is still the best cure - just stop buying plastic clothes. Kind of like how the way to adapt to the Roman habit of sweetening wine with lead and then serving in lead dish ware was to not drink leaded wine and eat out of wooden or other dish ware.

<comment><USER4> We still have to demonstrate that the choice to go cotton to avoid micro plastic release outweighs the tremendous water use that goes with cotton agriculture - water use that occurs in some of the most water scarce areas of the world.

And unless we're going organic consider the impacts of eutrophication and other chemical discharge/byproducts.

There isn't a silver bullet in material sustainability besides non- consumption. And we usually don't know (or agree) enough to weigh externalities against each other.

Its important that we study, assess, and (hopefully) mitigate the release/impact of micro plastics because their isn't a plausible path toward the textile product's industry to reduce it's carbon footprint in line with the UNFCCC without relying on recycled polyester.

<comment><USER4> Sorry for the typos.</comment></comment></comment></comment>


Law grad wins discharge of his student debt - <AUTHOR> http://www.abajournal.com/news/article/law-grad-wins-discharge-of-his-student-debt-in-opinion-criticizing-punitive-standards <comment><USER2> Bankruptcy is meant to be the point where the law decides the entity simply cannot pay its debts in a particular situation and what the next step(s) should be. Philosophically, if a debt cannot be discharged due to bankruptcy, isn't it really just some wacky exception to enable some form of slavery?

Are there other examples of "debt" that cannot be discharged through bankruptcy?

(Yes I know this case demonstrates student debt actually can be discharged)</comment>


Twitter accidentally suspends its own CEO's account - <AUTHOR> http://money.cnn.com/2016/11/23/technology/twitter-jack-dorsey-ceo-founder-account-suspension/index.html <comment><USER2> The interview was pretty interesting. Sacca's description of how they make it hard to follow what's going on, even though they know first, sums up why I don't use Twitter. Twitter always feels like I'm walking into the middle of someone else's conversation or inside joke. I rarely have enough context to engage, but people who like to just be loud, or talk to themselves, or don't have a clue can go to town.

Maybe I'm doing it wrong.

<comment><USER3> Back and forth discussions are not the primary use of Twitter. I had a hard time with that for years too before I finally "figured it out." You just need to follow a lot of people who share your interests and then your timeline will become more interesting.

<comment><USER4> It does... until everyone stops talking about those interesting things, and starts ranting non-stop about politics. I may even share their political views... but I'd rather be able to mute that garbage and only read about the stuff I have interest in.

<comment><USER5> Yeah, I follow mostly nerds and comedians on twitter. Up until this election season, most of my feed was nerds talking about things they built and comedians telling jokes.

Now my feed is literally 60% nerds talking about politics and comedians talking about politics.

<comment><USER6> I'm also something like this. Luckily, Americans are a minority in my feed, so while the previously topical tweets of those who I unfollowed will be missed, it was not a big change for me.

</comment></comment></comment></comment></comment><comment><USER7> Silicone Valley companies wield too much power when it comes to these sorts of things. This is just another example of this, if they don't self regulate there will be laws that regulate them.

Google was banning people's email and their entire digital life because of buying multiple pixel phones. This is an unrelated issue but they took it upon themselves to just use their unlimited power to screw people. It's like your electricity company shutting off your heat because you didn't pay for some stove, if they sold both things.

These companies would so themseves a lot of justice by setting up a this party group that manages hear abuses and is impartial.

<comment><USER8> "Silicone Valley" is actually in Southern California—land of the implants.

<comment><USER9> "You keep using that word. I do not think it means what you think it means." Inigo Montoya

</comment></comment></comment><comment><USER10> I wonder if Twitter is susceptible to mass report attacks. I strongly suspect many of these systems just automatically suspend someone for too many reports. This makes it convenient if you don't like someone else's politics to just get a group to mass report them and you can silence whomever you want.

<comment><USER11> This is definitely a problem which some users have been exploiting on twitter.

</comment></comment><comment><USER12> This illustrates the limitations of machine learning and automated processes when applied to the real world. Until GAI is achieved, you really need to couple ML with humans to correct the mistakes made by ML.

Think Iron Man, not Ultron.

</comment><comment><USER13>
      > just setting up my twttr...again
      > (account suspension was an internal mistake)

Did he really just abbreviate his company name ... and no other words?

<comment><USER14> throwback to his first tweet: [https://twitter.com/jack/status/20](https://twitter.com/jack/status/20)

Back then, Twitter was called twttr.

<comment> martin-adams Not just his first tweet, Twitter's first tweet.

<comment><USER15> Bull shit. We all know the first tweet was either 'test' or 'hello, world'.

<comment><USER16> ...followed by a whole lot of "gudsfgjhgfkjhgdasf"

</comment></comment></comment></comment></comment><comment><USER17> Did they restore his followers from a backup or do you keep them through suspension?

<comment><USER18> It's a suspension, not a deletion, which implies it's possible to resume the account. It seems logical that the state of the account would be entirely preserved for later restoration.

<comment><USER19> so why does the article report that only 3.8 out of 3.9 million followers were restored? While overall I would say that is pretty much a rounding error, if we look at it very carefully you have to ask: did literally 100,000 people proactively choose to unsubscribe, from an account that obviously remains important, and moreover during a time when it was inactive? Would his tweet have been so 'spammy' that 1 out of 39 of his every follower decided on that basis alone to unsubscribe?

If the full number of followers were not restored, it raises the question of why not?

I don't know how to get historical "number of followers" information - as of this moment :

[https://twitter.com/jack](https://twitter.com/jack)

the numbers I see are " 20.6K tweets, following: 2,2264, followers: 2.63M, likes: 15.1K, lists: 3"

for good measure and lest someone try to rewrite history here's a screenshot I just took: [http://i.imgur.com/JJQKPI9.png](http://i.imgur.com/JJQKPI9.png)

The figure CNN quotes is: "Soon after Dorsey was reinstated, his number of followers was showing up as only about 145 -- a steep drop from the roughly 3.9 million he had previously. The figure later popped back up to around 3.8 million."

So what exactly happened to cause 1.2M twitter followers to decide to unfollow him?

Sure, he's a heavy tweeter - I wouldn't follow him due to the level of spam - I mean who send 20,000 tweets in 7 years - that's 7+ per day at least.

but the people who _did_ choose to follow him - if the CNN quote above is accurate - aren't people I would expect to unfollow him exactly around this time.

So if CNN's figure is accurate -- what happened? And why the drop of 1 million subscribers, or in other words one in three subscribers that he had had?

<comment><USER20> in distributed systems, counts are often incrementally maintained over time. There are many ways to trigger an unfollow (e.g. account deleted or country banned), and all the edge cases must be explicitly accounted for, or error creeps in, which is probably what happened. 3.8M is probably the more accurate count.

<comment><USER19> I have no idea why anyone would downvote the current comment. I've edited to be clear I'm being totally open-ended.

>3.8M is probably the more accurate count.

You mean "than 3.9" right? So in an open-ended way, genuinely curious here, would you say the 2.63M he's at now (as I screenshotted for you) an "even more accurate" figure?

just trying to understand the change in figures - I don't have a horse in this race and can certainly accept your reasoning. I don't know much about how these counts work.

<comment><USER21> I don't know at all, but a number that high may be fuzzy like with reddit's voting system. At some point to save database queries, they may just approximate the number.

<comment><USER19> that's an interesting perspective - though fuzzing by 46% seems more than I would expect (but may be possible.) I got 46% by doing 3.8/2.6 (you can check because 2.6 * 1.46 == 3.8).

\</comment></comment></comment></comment></comment></comment></comment><comment></comment><comment></comment><comment></comment><comment></comment><comment>-----

EDIT: I didn't change above the line with this edit but - why would anyone downvote this comment too? when all I say is it's an interesting perspective. (There are no comment replies at this time, just a downvote.) Also I reread my comment and I noticed that it was not actually listed as 2.6 - but 2.63 -- so two sig figs.

I actually took screenshots (for myself) with my clock, this is an interesting change:

[http://imgur.com/a/CU7Qm](http://imgur.com/a/CU7Qm)

it's -0.11m change over about 2 hours 21 min. (take 7 seconds). I don't know what part of that is "fuzzing" (like reddit does) what part of that is lack of coherence (from distributed DB), and what part of that is the actual change.

I would think, if anything, it would move up during this time due to the extra attention - maybe HN, CNN and other readers would sub to him after reading this story. at any rate it's certainly a puzzle to me why anyone would downvote this comment. (I don't think it's malicious and there's just one downvote.)

<comment><USER21> Someone in this thread is down voting just about everything. I wouldn't take it personally.

</comment></comment><comment><USER22> Read this some where on some other forum, is this true?

> So yesterday someone found out that you can get any account banned if > reports reach ~1000.

Is this somehow related?</comment>


Ask HN: Non-english Tech Newsletters to recommend? - <AUTHOR> I'm pretty sure you can find great non-English tech newsletters (programming, sysadmin,...)  in Spanish, French, German, you name it.<p>Any great resources to share? <comment><USER2> French-speaking FOSS-oriented Tech Newsletter: Le Courrier du hacker [https://lecourrierduhacker.com](https://lecourrierduhacker.com)</comment>


Canadian dollar at par with American - <AUTHOR> http://canadianpress.google.com/article/ALeqM5hSPjtwINMoyVzOzvF2ivVPJMdsww Then falls back to parity <comment><AUTHOR> 'Canadian dollar outvalues American' was a much more eye-grabbing title. This is the tidbit people care about. The intraday high was US$1.0008. By anyone's measure, actually Wall Street's, which is the only one that matters, the Canadian dollar outvalued the American. Since this is a news headline, we use the present tense to indicate something that occurred in the past.

Tomorrow when the CAD falls below the dollar are we going to re-edit the title to say 'Canadian dollar well below American'?

</comment><comment><USER2> The US dollar has last between 30% and 45% of its value in the last 5 years depending on which currency you compare it against. This is unfortunate, but not too surprising.

</comment><comment><USER3> :(

</comment><comment><USER4> This will stay for next couple of years - Canadian economy is strong so even if US$ doesn't depreciate CN$ will keep on appreciating ... also a further rate cut is expected in US this will surely depreciate greenback - unfortunately goods at Canadian retailers are still expensive by 20% to 40% - but net customer can go on canadian websites of ebay, tigerdirect, etc. and buy cheap.</comment>


Being a Developer vs. DevOps Engineer - <AUTHOR> What are the exact tasks of a DevOps Engineer and why is there pay higher than normal developer<p>I am not saying that DevOps should be paid less than normal developers but I am curious to understand why is there salary higher than that of normal developers. <comment><USER3> I'm not sure the salary thing is generally true - but lets say it is - <USER2> reason is mostly supply/demand, there are less people with the wider base of knowledge it takes of systems and software or just general desire to do devops/cloud work than there are those that can do general software development.

<comment><USER4> I second this. I have recently switched from legacy development to AWS DevSecOps (I was/am an ASC in both roles). I do less development now, but I do more configuration-type work. It's more difficult than straight development, especially since the company doesn't really train us and we don't get a steady diet of one kind if work (today it might be a Python Lambda, tomorrow it might be Java ECS; I've never done the same type of work more than once in my 6 months on the team).

In my case, the salary stayed the same. So with more responsibilities and the same pay, I'm wishing I could go back to legacy development.

<comment><AUTHOR> That clears my confusion. So, basically if as a developer I end up setting CI/CD pipelines for my product. I am doing dev and devops job.</comment></comment></comment>


Strain Wave Gearing - <AUTHOR> https://en.wikipedia.org/wiki/Strain_wave_gearing <comment><AUTHOR> I hope someone has a diagram of this because the text description isn't great.

In concept, I wonder how similar it is to the "pepper grinder" of OskarPuzzles. [https://youtu.be/kYmUJVE6Vo0](https://youtu.be/kYmUJVE6Vo0)</comment>


Haskell Live: A Live Coding Adventure - <AUTHOR> http://haskelllive.com <comment><USER3> I have to say, I generally dislike video coding tutorials.

First, it's difficult to google/copy-paste. Second, it just goes against the way I learn new programming languages - I generally read it, then try it, then experiment with it in some other ways, list few pages back/forth, experiment more, fail, then continue. Usually copypasting/rewriting chunks of code. "What happens when I do THAT? Oh, it fails miserably. Why? Oh, that's why."

I can easily reread some parts. I can easily skim back/forth. While with the video, I don't want to hear the person more than twice, usually. The voice becomes annoying for the third time you hear it.

I feel that videos work great for _demonstrating_ a language. I can never actually _learn_ any language from a video tutorial.

(If you will bring the analogy of lecture - yes, this is partly true, but good lectures should be somehow interactive. The lecturer asks students, they can ask the lecturer back.)

<comment><USER4> "I can never actually learn any language from a video tutorial."

I like video tutorials/screencasts as long as they have the following :

1\. Trainer starts with a basic list of topics/table of contents. Nothing fancy but give me an overall overview of what I will learn out of this.

2\. A particular topic is taught gradually i.e. by starting with a simpler or even wrong way (as in best practices) and then improving it to show the more standard way. For don't just show me the final end product.Show me how to do it in a crude/simpler way, then improve the code (may be refactor etc) or add more features. Explain each improvement while you are doing it and WHY you are doing it.This makes us learn the gotchas and pitfalls and may be even best practices.For example, I can put all the code in one file to start with but then how can/should I refactor it in some recommended way? (MVC?)

2\. Show me more than 1 way of doing something if it helps me learn the concept. Again, kind of related to #1.

3\. Break the code on purpose and explain what the error message means. Then fix it and re-run. For example, in learning Django/Flask, if you are missing a template, it will crash/error out. So don't create the template right away. Build the code without template and let me see how it crashes. Then add the template and re-run to show me success.

4\. Unless you are teaching design specifically, save the HTML/CSS/JS tricks/enhancements for the end. Show me the core product.

I am sure there are more but these help me a lot personally. In fact, I am learning Python/Flask right now and looking to write my own tutorials on how I learnt it.

<comment><USER5> These are great points and I will do my best to incorporate them in future episodes. Thanks very much for taking the time.

<comment><USER6> Also, would love to see some explanation of basic Haskell concepts

</comment></comment></comment></comment><comment><USER7> This is somewhat of a nitpick, but for one thing, writing code that is as obviously correct as possible is important in every language, not just in Haskell. Compositionality is one of the most valuable things we can exploit when programming.

For another thing , the assertion that enumerating all the cases for a given function instead of using a lookup makes the code more obviously correct is somewhat flawed - it violates DRY, which is, like exploitation of compositionality, important in programming in general. Suppose the showPiece function had twice the number of cases. Would enumerating the cases individually or making the assertion that the code is more obviously correct as a result be reasonable?

In my view, you are solving the same problem whether you use a lookup or enumerate the cases individually, and it's not even a very big problem - <USER2> put your tokens in the right order.

</comment><comment><USER8> This is awesome. Nice and approachable - well explained. I'd love if you also threw in some vim commands along the way.

<comment><USER9> I'd like to respectfully offer another opinion: I would NOT love if it some vim commands were thrown in. By all means, devote a single episode to tools, since the set up demonstrated might be complex to recreate, and it would likely be something a lot of people want to use too. But I don't think tips specific to a single editor have any place in screencasts that are about one programming language in general.

An unobtrusive way to introduce editor tips that just came to mind would be to add subtitles with selected key-combos that might be nontrivial or not obvious. More than that would be a distraction, I think. Also, I don't know if YouTube supports multiple subtitle tracks... so that might be a big fu to deaf or hearing impaired programmers who want to follow along.

<comment><USER8> Great suggestion, that's on par with what I had in mind. I was not implying OP should have a 3-minute segment on vim commands. Maybe just casually say "and I'm going to use :tab which allows me to select multiple lines and line up the equal signs" or something similar.

<comment><USER9> > Maybe just casually say "and I'm going to use :tab which allows me to select > multiple lines and line up the equal signs" or something similar.

No, I wouldn't want them to casually _say_ anything... that's why the subtitles would be an unobtrusive compromise, since you can just turn them off. I think this would be even more important if the screencast was targeted at new users of the language or framework or whatever, since the viewer might be confused and wonder if ":tab" was something to do with the syntax of the language.

<comment><USER5> I want subtitles to perform their primary accessibility function. How about YouTube annotations?

<comment><USER9> I had forgotten about annotations, those might be ideally suited for editor and env tips. Honestly, I use Emacs, so I'm not that interested in the vim tips, I just didn't want these to turn into a series of Haskell-with-Vim casts. :) even thought your env does looks pretty slick.

Really nice video, looking forward to more!

<comment><USER5> Yep exactly. I want to keep the videos per se as env-agnostic as possible to not get in the way of the Haskell.

</comment></comment></comment></comment></comment></comment></comment><comment><USER10> Very cool. I don't have many Haskell coders where I spend my time, so it is nice to watch how someone with more experience tackles fairly basic programming tasks. The guard window and quickcheck in particular were eye- opening.

</comment><comment><USER5> Thank you all so much for your feedback. And thanks to the OP for posting this. I can't make everyone happy all the time but I'll do my best to make each episode better than the last.

<3 HN

<comment><USER11> Don't change too much, it's already a splendid format!

</comment></comment><comment><USER12> Good workflow, nice simple start with chess types and the serialization/deserialization thereof. Enjoyable watch.

<comment><USER13> I also really enjoyed the pacing and voice. I'm looking forward to the next episodes.

</comment></comment><comment><USER14> Good screencast, there's a mistake regarding the piece colouring though. They're all black because all the characters are lowercase (and I think you meant to make the bottom row uppercase).

It can be verified in the code, and in the REPL when it's being tested.

</comment><comment><USER15> For all those interested in emacs haskell mode this <http://www.youtube.com/watch?v=E6xIjl06Lr4> is about the best screencast I've seen covering the new stuff the Chris Done wrote. I'm using emacs prelude and it's a great environment right out of the box!

</comment><comment><USER16> What is the editor / configuration used in the video ?

<comment><AUTHOR> Looks like tmux + vim, using the Solarized Dark theme.

<comment><USER16> I gathered the vim part. Is he pressing a separate key to run the stuff in the lower-right window or is there a vim hook to do that automatically?

<comment><AUTHOR> For that I think he's using Guard (<https://github.com/guard/guard/>)

<comment><USER5> I'll make a video on my setup, but:

Left: vim with Vim Haskell Mode[1], a pale imitation of emacs haskell minor mode that nevertheless gets the job done. ;)

Top right: GHCi

Bottom right: Guard, as mentioned, using guard-shell[2] to compile the file and run main using runghci.

[1] <https://github.com/lukerandall/haskellmode-vim> [2] <https://github.com/guard/guard-shell>

<comment><USER16> Maybe that info should be on the page itself somewhere. I wouldn't know to look at the github to find your guard script: [https://github.com/haskelllive/haskelllive/blob/master/Guard...](https://github.com/haskelllive/haskelllive/blob/master/Guardfile)

<comment><USER5> Good call. I'll add that to the About. I'm going to do a quick supplemental vide on the setup as well between now and next episode.

</comment></comment></comment></comment></comment></comment></comment><comment><USER17> This looks interesting. I somehow really like Haskell, although I never got around to dive into it. It's one of those languages that I want to learn one day but never have time to. So, watching those videos is kind of showing me how things are done the Haskell way, which is kind of strange for somebody like me who's entirely used to C89 ;)

</comment><comment><USER18> This is really cool. I wish I had more free time, but I will be using what little I have for this (and learning vim as I go).

</comment><comment><USER19> Good job!!! I'm looking forward to the next episodes.

</comment><comment><USER20> Awesome! This is exactly the kind of learning experience that would be useful to someone who has been studying Haskell intensely for a week.</comment>


Show HN: IPOs.fyi – Missing Out on IPOs Was Frustrating, So I Fixed It - <AUTHOR> https://ipos.fyi <comment><USER2> IPO calendar for NYSE: [https://www.nyse.com/ipo- center/filings](https://www.nyse.com/ipo-center/filings)

IPO calendar for NASDAQ: [https://www.nasdaq.com/market- activity/ipos](https://www.nasdaq.com/market-activity/ipos)

Market Watch's IPO calendar: [https://www.marketwatch.com/tools/ipo- calendar](https://www.marketwatch.com/tools/ipo-calendar)

Anyone know if CBOE publishes an IPO calendar?

<comment><USER3> Seems a bit disingenuous for the creator to scrape public info and then charge for it. Like everyone else has said, can't see what the product is, but to pay 20$ a month for notifications and a "community" that could contain 1 person or 10,000 people seems a bit much.

I think it would be beneficial to reposition to "Help find the best IPO to buy" because saying that this data doesn't exist for free is just not true and makes me a user feel like you are running a get rich quick scheme.

Not to say that there isn't value here. I think people would love to discuss IPO's and making it easier to do research, etc. is definitely a value add. Just think the messaging needs to change.

Also, you mentioned that the 20$ (or 240$ per year) will be made back and from an investment standpoint, that's also not necessarily true. Think it's praying on the misconception people have that IPO will always be profitable so I should pay 20$ to invest right away.

<comment><USER4> Disingenuous? There's no value in collating information from different sources?

None of the words on the home page imply the information can't be manually collated for free.

And this is a Show HN, it's reasonable to assume you would be the first person in the IPOs.fyi community. That doesn't make anything OP is doing disingenuous. All communities start with 1 person...

</comment></comment></comment><comment><USER5> My brokerage (Fidelity) does this for free. But the problem is not knowing about the IPO, it's getting an allocation. As a retail investor, it would seem my position size is not big enough to get any shares. I know this varies by brokerage, so this may or may not be typical of others.

If you could pool together retail investors to increase the possibility of getting shares allocated, that would be something special...

<comment><USER6> It's not quite the same, but the ETF's; USA - IPO, FPX; and International - IPOS, FPXI, FPXE.

They buy IPO's after they launch, and then sell them after a set duration, automatically managing inflow of new and outflow of old. Youre not able to buy specific companies, youre instead buying into the idea, trends, and behaviors of IPOs as a whole. They also dont capture the huge initial jump in price.

Go with a 60:40 IPO:FPXI to capture all the ipo momentum in the world.

<comment><USER7> > They also dont capture the huge initial jump in price.

I don't understand why this is allowed. Why don't they structure IPOs as an auction, such that the initial sale is at the market price.

<comment><USER8> Half corruption, but the surface argument is:

Companies want stability. If my plan is to raise $2 billion with an IPO, I want to be able to build a business knowing that money is coming in. With an auction, I wouldn't know how much money will come in. It might be $4 billion, or it might be $500 million.

The current structure has a financial intermediary who charges a premium to take the risk of a price DROP for me. I can shop around for who will give me the best price, and once I've got that locked in, I know my $2 billion will come in, and I can start building my engineering, marketing, etc. with the stability of a guaranteed check in the bank.

That stability is worth more than the premium.

<comment><USER9> It can't be difficult to design an auction where the amount of $$ raised is set, with the "price" being the valuation (ie. what % of the company the investors are willing to own).

<comment><USER10> That's basically how Treasuries are auctioned. The problem for an individual company is I might be interested to IPO only under certain terms and be willing to pay a middleman to arrange that for the certainty. (The Treasury auction isn't likely to move much and when it does, well, that's the price-the government needs the cash to run; that's not quite the same as a company who has other possibly viable options, including waiting.)

[0] - [https://www.treasurydirect.gov/indiv/research/indepth/res_au...](https://www.treasurydirect.gov/indiv/research/indepth/res_auctions_indepth.htm)

</comment></comment></comment></comment></comment></comment><comment><AUTHOR> A few times I saw news about a company that I liked and, upon Googling, noticed that it had gone public a few weeks prior. By this time, the stock had already shot up. So I set out to fix this problem and built IPOs.fyi.

It's by no means finished but I am proud that I built my first software product and would love feedback. If you are interested, you can use promo code HN20 for 20% off the first month!

<comment><USER11> Congrats on the MVP. People who are serious about getting these notifications are likely subscribing to IPOscoop or something similar. Not meant to discourage but feels a bit beta to me. Get eye balls and iterate. There are a lot of problems buried in EDGAR filings that I believe people are willing to pay for.

<comment><AUTHOR> Thank you! I definitely agree, this is an MVP for sure. Any feedback you have? Any ideas on a direction I should take it?

</comment></comment></comment><comment><USER12> This is an interesting concept however I think it is priced too high. I also agree with others that it would be helpful to see what it looks like before signing up. Good luck!

<comment><AUTHOR> Thank you for sharing this feedback, it's something I was wondering. My thinking for this pricing is that if you just act on one of the signals and are right, you will hopefully have a return of more than a year's worth of subscription costs YMMV

<comment><USER13> I think if you are submitting a Show HN, it is frowned on if there is no way to see it without paying.

From the guidelines, although its not explicitly stated I would think your submission here is not really playing the game. Just a heads up (and I may be wrong, but that's been said before), best wishes with it anyway.

 _Show HN is for something you 've made that other people can play with. HN users can try it out, give you feedback, and ask questions in the thread._

<comment><AUTHOR> I appreciate this, I thought I was following the rules but it's possible I am not. I messed up with not having at least some kind of free tier, though I did add a email sign up to send to people when I do build it. Thanks for the heads up!

</comment></comment></comment></comment><comment><USER14> This may come across as pedantic, but the terminology on the page is a bit imprecise and may suggest a lack of sophistication for somebody selling a financial information product. You're not helping anybody avoid missing out on an IPO because you're not helping anybody be part of the IPO market itself. (Generally only big investors with a relationship to the underwriters or friends of the issuer get to be participate in the IPO market, i.e. to buy shares in an IPO.)

You're offering to let people know that shares will be available in the secondary markets the day after the IPO is priced and shares are sold (often buying FROM people who bought in the IPO). The distinction here is important because in an IPO that "pops" on the first day of trading, somebody who buys shares on the secondary market in normal trading is not going to be able to buy them at the IPO price. (They may even have a hard time buying them at the opening price in secondary trading...)

</comment><comment><USER15> I built the same product back in 1998. It worked well during a heightened time of new IPO listings. Not always the case. but I was able to sell it to a hedge fund back then 2 years later. good luck!

</comment><comment><USER16> I would love to get a free preview or 7 free days or something before I decide to pay. Would like to see what the content looks like :)

<comment><AUTHOR> Heard this feedback from a few folks and definitely agree. How do you think I should differentiate the paid vs free option?

<comment><USER17> Perhaps make all the past notifications you generated fully visible with no login required. Nothing sensitive about the past? Show the dates you'd have sent the content and what it would have looked like. Would be good for SEO too I think.

<comment><USER18> I think this is an interesting approach.

</comment></comment></comment></comment><comment><USER19> Definitely agree with the mission. I believe it should be free though, so we created Today's IPOs: [https://todaysipos.com/](https://todaysipos.com/)

We are trying to democratize finance!

</comment><comment><USER20> I'd suggest putting the information directly on your site (at least the IPOs coming up in the next X days) and charge for the deeper access + email notifications. But that way people have a reason to visit your site even if they haven't decided to pay yet.

</comment><comment><USER21> The economics of IPO investing seem to reward the early private investors at the expense of retail investors. In the current market, I question this as an investment strategy.

"Oh no, I missed the IPO" turns into "well, at least I can buy at a discount" 6 months later. This isn't _every_ company, but it's been an increasing portion as of recent years.

</comment><comment><USER22> Nice idea! I think for people who constantly want to invest in the next big thing, this would come in handy.

As an aside, a good friend of mine warned me that investing at the beginning of an IPO generally is a bad bid. It's better to wait 1-2 years until the hype settles to fairly value a company and that is so true from my own experience with $SNAP, $UBER, $LYFT and $PINS.

</comment><comment><USER23> If you are interested in following SEC filings of companies, I wrote a RSS- bridge against Edgar which takes in tickers and sends a notification every time that companny files something to the SEC.

Code: [https://github.com/RSS-Bridge/rss- bridge/pull/1011](https://github.com/RSS-Bridge/rss-bridge/pull/1011)

If you have a list of tickers, you can generate a OPML feed from here: [https://opml.bb8.fun/](https://opml.bb8.fun/) (against my rss-bridge server, no uptime guarantees)

</comment><comment><USER24> This is not supposed to be a "Show HN" post, right? I remember that in the guidelines this tag is meant for something that we can see the inner workings and hack with. This is a mere product promotion post.

</comment><comment><USER25> I've been curious what the hypothetical outcome would be if you were to invest the same amount of money in every IPO for the past 30 years and sell at a fixed time 10 years later. Are IPOs underpriced, overpriced, or neither on average over the long term? How does the return compare to investing the same amounts into the S&P 500 or similar benchmarks over the past 30 years?

<comment><USER26> there is an ETF that does this, at 2 years rather than 10. [https://www.renaissancecapital.com/IPO-Investing/US-IPO- ETF](https://www.renaissancecapital.com/IPO-Investing/US-IPO-ETF). Performance ITD has been worse than SPY until very recently when a lot of tech companies (incl IPOs) have had very strong performance... which is obviously why this thread is even happening.

<comment><USER25> Interesting... although 2 years doesn't seem like a meaningful enough time frame to capture real growth, only hype.

<comment><USER27> Which is the strategy no doubt!

</comment></comment></comment></comment><comment><USER28> I recently made something similar, but for movie directors: [https://directoralerts.website/](https://directoralerts.website/)

</comment><comment><USER29> not sure why everyone is trashing this person's service. if you have >250k in your TDA account to gamble on IPOs, think $19 for a notification service on upcoming ones is reasonable. that being said i signed up and when i click on one of the ticker names i get a heroku error, so while the idea is solid just not completely functioning.

edit: working now.

<comment><AUTHOR> Sorry about that, was deploying some updates. Should be working now.

<comment><USER27> Yeah try to fix that from happening in future. You need it to swap not shut down when updating. I will check my Heroku too!

</comment></comment></comment><comment><USER30> heads up - you need to offer a free way to try your product or it will be delisted from Show HN. trust me it happened to me.

</comment><comment><USER31> This is an awesome idea, good luck

</comment><comment><USER32> Looks like a scam. No thanks.</comment>


My "Ember" Job Posting on Hacker News - <AUTHOR> https://gist.github.com/Blackshawk/5308087 <comment><USER2> Hey all, Jarrod Nettles here (hayvok - OP).

The original code base was in PHP. Very, very terrible proceduralish PHP. Since we have to continue to maintain the current system while we rewrite we can implement once and port that code (if necessary) to the new system with minimal effort.

Could I switch us to Rails? Yes, but I don't see the point. We're a PHP shop and in my professional opinion (having used both extensively) Symfony 2 is virtually on-par with something like Rails and switching at this stage of the game would be project suicide.

* If you're using Rails, and like it - stick with it.

* If you're using a good PHP framework like Symfony 2 or Zend Framework, and like it - stick with it.

You'll be just as productive and successful either way.

<comment><USER3> I agree. My primary languages are C# and PHP. My C# background heavily influences the way I write PHP code using heavy OOP principals and even type- safety (using instanceof) where needed.

I avoid using associative arrays as return objects when arrays of real objects (or type-safe collections of objects) are better suited.

So I think that you can write really nice code with PHP and a good framework. It's more about the software architecture than the language.

</comment></comment><comment><USER4> Sounds like a perfectly normal professional stack to me: solid tried and proven technology at the foundation for the generic solutions, more hot new stuff around the edges to optimize for specific cases (and let's face it, sometimes just for the hell of it).

It's only the inexperienced unprofessional wannabees that bitch about anything that doesn't use all the cool new toys top to bottom, and try to solve every problem using the coolest tool instead of the most appropriate.

And the only thing "wrong" with PHP is that it's inelegant and inconsistent as language. 90% of the people bitching about PHP couldn't put two solid arguments together.

The argument that it attracts the worst programmers is no longer true since Ruby's "coolness" started attracting large numbers of less than mediocre programmers, proving publicly on Github that you can write crappy code in even the most elegant of languages.

<comment><USER5> Even if it were true that "90% of the people bitching about PHP couldn't put two solid arguments together," not only is that irrelevant to PHP's merit or lack thereof, it leaves a whole lot of people with valid arguments.

Further, "the only thing "wrong" with PHP is that it's inelegant and inconsistent as language" is your opinion. It is most certainly inconsistent, yes. It also grows and changes in strange, illogical ways, has a history of horrendous built-in defaults and security practices (e.g. REGISTER_GLOBALS, which had a very long life and is likely still enabled on a whole heck of a lot of servers). There are many reasons to avoid PHP.

There are also reasons to avoid most other languages. I and many other people, however, believe that PHP is so far ahead on that list as to be a liability in and of itself.

You're making even more unsupported assumptions regarding what attracts people to Ruby, and I don't know whether this is false dichotomy or some other logical fallacy, but "you can write bad code in Y as well as X" says absolutely nothing about X.

In the end: Yes, if you're careful and skilled, you can probably write solid, secure code in PHP. However, there are more roadblocks to this pursuit in PHP than in any other language I've worked with (9 years of experience in PHP, 6 in Python, less in various other relevant languages).

<comment><USER6> Thank you for your reply!

I had written one vaguely similar to yours but ended up not posting it because i was seething with anger.

I just don't understand how so much vitriol continues to bubble up on HN posts like these.

</comment></comment></comment><comment><USER7> You can tell someone who hasn't had broad professional experience when they are aghast at the idea of a multi-technology stack like this. The reality is any company bigger than startup size is going to be using lots of different technologies for lots of different things, for a variety of reasons. Hopefully all good but sometimes not so good.

I'm curious about the choices that lead to doing the API in PHP/Symfony as opposed to Node, though. I've written APIs in both PHP and Node and it seems to me that Node has the advantage in terms of being more lightweight for the task. So I'd love to hear what Jarrod sees as the advantages PHP presents that make it a better fit.

EDIT:

Got the following response to the question on Twitter, for anyone else curious:

> I have but honestly I'm just not comfortable enough yet w/ Node to a jump. > :) We're capable and productive w/ PHP. Maybe in time.

So, totally solid reason. :)

</comment><comment><USER8> > _We're rebuilding an internal app from scratch and it needs to be blazing > fast and real-time._

At risk of dragging the OP into a framework/language war...if you're building an internal app from scratch...why use Symfony? Is it because the rest of the Apple internal apps are in PHP/Symfony and it doesn't make sense to have the internal app group write in different frameworks?

(I'm assuming different languages isn't a huge deal, since the OP mentions using Ruby to handle deployment)

<comment><USER9> OP commented here, but didn't respond to you. They most likely went with Symfony since the original codebase was PHP. Porting to Symfony2 gives modern MVC web app framework tools and structure but has the same environment requirements. So there is very little cost as opposed to switching languages. The Ruby deployment methodology most likely uses Capifony a special extension to the Capistrano ruby gem for deployment built around Symfony and Symfony2.

</comment></comment><comment><USER10> _> In my opinion [Ember.js] the best client-side MVC framework out there._

How does Ember.js compare to AngularJS and Backbone.js?

<comment><USER11> It's yehudized.

</comment></comment><comment><USER12> Interesting. I don't work for quite so sexy a company as Apple, and positions aren't going to get you working on much hot new tech, so I'm not sure I'd post "we're hiring". I assume most people here have no desire to work at boring old companies, hence the "Wtf php? Are you a noob?" type comments.

<comment><USER13> _I assume most people here have no desire to work at boring old companies_

That's a really bad assumption. It's actually very difficult to find jobs with established companies because they maintain such a low profile. I wish they would be better at promoting themselves.

<comment><USER12> Monster.com and the company website usually have a bunch of job listings for the older companies. If you want to work at IBM, Intel, Comcast, Microsoft, Oracle, HP, etc. it isn't hard to find job listings. I'm not sure if if posting on HN is going to attract more applicants for them.

Perhaps those weren't the type of companies you thought I meant, but I work for a company in that category. If you like c#, c++, or Java and love rain 8 months out of the year, we might have a place for you in Oregon...

</comment></comment></comment><comment><USER14> I must've missed the who's hiring thread. I'll tack it on here.

If you want to get in to Ember, we've been using it in production since 0.6. We'll be actively hiring people pretty soon.

Deets are: We're in Manhattan, NYC. We're a team of 3. Use Ember.js, Rails, D3.js and a bunch of crazy backend things including custom stuff. Have lots of paying customers. Lots of money in the bank and we're on our way to be cash flow positive this year.

My contact info is in my profile. We hire opportunistically so while we're not actively looking to fill a position, if you'd be an amazing person to join us, I'd hire you.

</comment><comment><USER15> +1 for polyglot, but I find PHP in the mix strange though. Is there a reason why you think PHP/Symphony2 is the best choice?

<comment><USER2> See above. :)

</comment></comment><comment><USER16> > The thing that amazed me the most - virtually every applicant was downright > giddy at the opportunity to work with Ember.js full-time.

Of course people want to work fulltime on the latest hotness in javascript. I'm surprised that you're surprised.

</comment><comment><USER17> interesting contrast to the recent HN post about how poor the responders to a 'HN: Who's Hiring' post were.

</comment><comment><USER18> That job posting couldn't be more boring. You'd have to kill me to get me to consider that job.

<comment><USER19> Be careful with that edge, son, you may cut yourself.</comment></comment>


Ask HN: Twilio Support Escalation Contact - <AUTHOR> Hi HN,
I'm the CTO of a startup in Kenya who just started using some of the Twilio Beta numbers here.
When we first started using them, we noticed that the price we were getting billed was ~30X higher than what was posted on their website for the beta number. We contacted their support, but it seems the quality has dipped quite a bit.
Does anyone have a good contact for Twilio support that could help us?
~Earl <comment><USER2> Hi Earl,

You can already get local voice numbers at affordable cost from Africa's Talking (www.africastalking.com). We offer free support in case you experience any issues. Feel free to contact us on firstname.lastname@example.com

\- Sam</comment>


Scribd sued over copyright - <AUTHOR> http://arstechnica.com/tech-policy/news/2009/09/scribd-sued-over-copyright-by-jammie-thomas-lawyers.ars

<comment><USER2> Im not hugely surprised since I saw the Scribd links appearing automatically next to PDF submissions here on HN.

If they made it _that_ easy to break copyright it was only a matter of time before someone sued.

EDIT: I dont mean to say HN/pg are at fault - I just mean they were providing an API along the lines of scribd.com/scrape?url=[url of the pdf] (which is/was what was used here) which scraped and saved the document. That's just asking for trouble.

<comment><USER3> _That's just asking for trouble._

Just like Google's cache is?

<comment><USER4> Ah but Goggle is a big boy with lots of money. It's much easier to pick on a smaller opponent.

<comment><USER5> The strategy may be in fact to take down a smaller case and use it as a precedent to go after larger companies.

</comment></comment></comment></comment><comment><USER6> See also:

<http://news.ycombinator.com/item?id=834352>

<http://news.ycombinator.com/item?id=832142>

There's already a great deal of discussion on the first of those, so it might be worth reading that before commenting here.

FWIW, I think that what scribd does is a Bad Thing(tm). I can image having to check every week whether something I've written and copyrighted has appeared on their site, and I think it's unsupportable that they say "It's your problem to check - tell us and we'll take it down."

Perhaps it would be interesting to require that any money made from having my work on their site must be transferred to me with interest. Further, to require that such accounting be made auditable. If they make money while my work is on their site in breach of my copyright, why shouldn't I get it?

Still a nightmare to enforce. Every author constantly having to check to see if their work has been pirated.

<comment><USER7> >I can image having to check every week whether something I've written and copyrighted has appeared on their site, and I think it's unsupportable that they say "It's your problem to check - tell us and we'll take it down."

But that's the law. The DMCA states that service providers don't have to do filtering or checking before they're notified of a violation. Scribd (according to the article) is even making it impossible to re-upload a document taken down under the DMCA. So they're doing more than the law requires.

What would you have Scribd do? It's not like there's a database of every copyrighted document ever, so they can't blacklist documents.

<comment><USER6> I think the law is fundamentally wrong. I think there should be some sort of requirement on those uploading to assert that they have the right to do so, and there should then be a means of pursuing those who upload material to which they have no rights.

Yes, scribd is probably within the law, but they are acting in a manner that I find immoral, and I'm not the only one.

The upshot, as so many others have observed, is that copyright law is a mess, as is patent law. Completely absolving vehicles for theft such as scribd from any form of liability is wrong.

However, the law has never been about right and wrong, so it won't start now. I've largely stopped writing now, concentrating on personal appearances. That at least turns a tidy profit, and is difficult to duplicate without my knowledge. My other company relies on commercial secrets rather than paying through the nose to divulge secrets, only subsequently to have to pay to find if they're stolen, then pay again to defend them.

With regards scribd and its ilk, I know I won't get my way. Morals can't be policed, because laws will always be gamed. I don't like it, but I'll have to accept it. I just won't play. Apart from continuing to check for infringements I won't use their site. It's an old-fashioned view, but quite simply, it makes me feel grubby.

<comment><USER8> > I think there should be some sort of requirement on those uploading to > assert that they have the right to do so, and there should then be a means > of pursuing those who upload material to which they have no rights.

Scribd actually _does_ do this:

        [] By checking this box, I agree that I understand the
        Scribd Terms of Service and Copyright Policy and that
        my uploading of this material complies with those
        policies and does not violate anyone's rights.

<comment><USER6> Although you quote it, you are ignoring the second half of what I said. _"There should be a means of pursuing ..."_

Example.

I submitted here to HN a link to a PDF which is copyrighted. That has been uploaded to scribd without acknowledgement. When I contacted scribd to ask them to take it down they said it was the responsibility of the copyright owner to make a formal request for takedown.

Who ticked the box? I certainly didn't. Who checked that the person ticking the box had any right to do so? Scribd certainly didn't.

Scribd make no effort to ensure that copyright is not breached. There is no traceability. Their "efforts" are ineffective and insufficient.

Someone made a comparison with ISPs. The difference is that if I host material in breach of copyright, my ISP can cut me off. Getting back on is a pain, and costs money.

If someone uploads material to scribd in breach of copyright, there are no sanctions, there is no culpability.

It might be legal, but I believe it to be immoral.

I'm repeating myself. Perhaps I should shut up and go away before I get _really_ angry.

<comment><AUTHOR> You probably should get really angry, cuz you seem to have a insider's view into Scribd's back end. If not, then you're just bloviating and making strawman arguments that don't really stand up.

<comment><USER6> Hmm. Here, extracted from the comment above, is the basis of my point of view

        I submitted here to HN a link to a PDF which is
        copyrighted.  That has been uploaded to scribd
        without acknowledgement. When I contacted scribd
        to ask them to take it down they said it was the
        responsibility of the copyright owner to make a
        formal request for takedown.

        Who ticked the box? I certainly didn't. Who checked
        that the person ticking the box had any right to do
        so? Scribd certainly didn't.

From those facts I concluded:

        Scribd make no effort to ensure that copyright is
        not breached. There is no traceability.  Their
        "efforts" are ineffective and insufficient.

There was a breach of copyright, and certainly I wasn't contacted. I'm assuming the author wasn't contacted - scribd certainly don't appear to be proactive in contacting the author of everything uploaded.

Someone has uploaded copyrighted material to scribd, and it's still there. Hence I conclude:

        If someone uploads material to scribd in breach of
        copyright, there are no sanctions, there is no
        culpability.

Now, would you care to point out the strawman argument? I would be delighted to learn that a service I have hitherto thought of as the scum of the Earth are, in fact, noble and just.

No, really, I would, and I'm just being selfish. Currently I get very angry thinking about their existence, and if I learned that I was wrong I'd be happier.

Please.

If you can't, then I suggest that when you say:

       ... you seem to have a insider's view into Scribd's
       back end. If not, then you're just bloviating and
       making strawman arguments that don't really stand up.

then your logic is faulty.

</comment></comment></comment></comment></comment></comment></comment><comment><USER9> My problem with Scribd is that anyone can violate copyright on Scribd, but only the victim (the copyright owner) has standing to report it. On their copyright page, you can submit a DMCA takedown request, but the sample notice starts with "I am the exclusive rights holder/duly authorized representative of the exclusive rights holder". What if I'm neither, but I am a random web surfer who knows that Scribd certainly shouldn't be publishing a PDF of a recent NYT bestselling book?

If any Joe has the ability to use Scribd to violate copyright, then any Jane should be able to have it taken down if she has compelling evidence it's a violation.

<comment><AUTHOR> Because "compelling evidence" can be easily fabricated. Just ask all the writers that have had their works expunged from the Internet because an ex- wife, ex-writing partner, or angry reader decided to claim copyright infringement in order to mess with them. It happens all the time.

The valid affidavit requirement in the DMCA is a strong deterrent to this kind of nefarious abuse.

</comment></comment><comment><USER10> Kiwi Camara has a bit of a controversial past himself: [http://en.wikipedia.org/wiki/Kiwi_Camara#Racial_controversy_...](http://en.wikipedia.org/wiki/Kiwi_Camara#Racial_controversy_at_Harvard)

</comment><comment><USER11> Personally, I would like to see the authors sales before and after appearing on Scribd. Personally, I often search for reviews and/or excerpt from books before I actually go out and purchase them, much like I do with music and albums. Scribd has been an awesome resource for this practice. Otherwise, I would probably not purchase anything without reviewing bits of it beforehand. IMO, she may also profit from this exposure. Again, this could not be determined until we see before/after sales. (if she had any at all seeing the age and nature of the book, its likely to be outdated.)

</comment><comment><AUTHOR> Think what you want about Scribd, the case is really loopy and weird.

</comment><comment><USER12> Class action lawsuit immediately makes me think of sharks smelling blood in the water.

</comment><comment><USER13> "I'm shocked, shocked to find that gambling is going on in here!"</comment>


On Building My Own Artificial Pancreas - <AUTHOR> https://liamz.co/blog/im-a-cyborg-now-on-building-my-own-artificial-pancreas/ <comment><USER2> So, for those of you that feel that this is worthy of hacking: Diabetes is one of those diseases that seems right where your average hacker would like it to be. A single value (Blood Glucose Level) which you can read using some sensor and an automated delivery method. Connect A to B using some 30 lines of Python and call it a day. But it is not that simple. The manufacturers of these devices have to go through some pretty strict testing regimes in order to ensure the devices work well _when produced in quantity_. And that is where the trick lies. Doing this once, for yourself with nobody at risk but you if you fuck up and getting away with it is easy. Doing it repeatably for 10's of millions of people with all your risks analyzed and regulators happy is very, very hard.

<comment><USER3> meh still it seems extremely trivial for pretty much any well funded startup to do... and extremely surprising that it does not exist. i mean if theranos can exist, why the hell is this problem not solved?

<comment><USER2> Well funded start-ups (and established players) are all working on this. Given that the market is huge and Diabetes is yours for life you can bet that a lot of clever people have spent a lot of time on this. Not all of the companies that work on this problem have made it, on top of that it is a patent minefield. It will take you a few 10's of millions of $ or Euros to get to market and you would need to do everything right the first time. Then you still don't know much about how your device will function in the field until enough time has passed that you can judge by the returns where you got it wrong. Doing a respin is expensive.

So, Theranos can exist, and if the money that had gone to Holmes and then this indeed would be a solved problem. But it didn't. Note that there are pumps with a closed loop option on the market _today_ , but they are neither convenient nor simple to use. It is work in progress. I fully expect a simple to use closed loop system to be available in quantity somewhere in the next year or two based on recent market research. The time is indeed ripe. The basic tech is there and the pumps have achieved a level of miniaturization and reliability that it is feasible, there are still problems to overcome but those are all within the realm of the possible, do not require unobtanium and enough parties are working on it (competition is fierce) that at least one of them will solve it within that time frame.

</comment></comment></comment><comment><USER4> It's a damn shame that years after this became a thing we are still waiting for a proper commercial product to hit the market _at a reasonable price_ , I had a male relative with T1 diabetes and it was a complete burden on his life, We have the technology to improve peoples lives markedly (because we already did) but because of what the author mentioned in the article and the lack of "skin in the game" manufacturers are still dicking about and a lot of this only works because those manufacturers couldn't secure a blowjob in a brothel.

$8000 is just insane (yes I know FDA approval, testing all that jazz) but there ~1.3m Americans with Type 1 diabetes alone, there is a massive demand for a cost effective product at scale.

<comment><USER5> Making a hardware product that is validated in a regulated market is non trivial. At least part of the cost goes to reducing overall risk to a large market, which open source projects aren't really resourced to address.

<comment><USER6> Isn't it possible to design the product such that its risks are greatly reduced? E.g. by limiting the amount of insulin it can deliver in a given timeframe?

<comment><USER5> This comment falls under the "why don't you just..." cluster. Even implementing a feature like that (assuming it made sense) carries risk (imagine if your limiter's sensor broke and it failed open).

Designing reliable systems is incredibly hard. It requires a ton of resources (money, lawyers, engineers) And experience and long time frames with relentless effort to document everything so that when somebody does die, you can root cause it and fix the problem without regressions.

I've been continuously impressed with what open source hackers have done with open biology projects, but that doesn't mean any of these products are reasonable replacements for the products that are used by tens to hundreds of millions of people.

<comment><USER2> > This comment falls under the "why don't you just..." cluster.

It does, but just this once it is _spot on_ , the best pumps on the market do just that.

<comment><USER5> yes, it's spot on, but only a tiny part of a much larger system. And even implementing that feature is devishly complicated. Hence my statement "why don't you _just_ ".

</comment></comment></comment></comment></comment></comment><comment><USER7> I'm curious what the build-your-own-pancreas people have to say about Tidepool's plan to build an iOS app to do the control logic, and at the same time developing standard interfaces to insulin pumps and glucose monitors. Any comments?

[https://www.tidepool.org/blog/tidepool-loop-medtronic- collab...](https://www.tidepool.org/blog/tidepool-loop-medtronic- collaboration)

<comment><USER2> > Any comments?

I hope they don't mess up the encryption on the pump commands. Especially with pumps that can deliver high doses that can be really problematic.

<comment><USER8> Is it possible to have interlocks whereby a pump will refuse to dose more than X ml over Y hours or is a fatal dose for some people in some scenarios less than a therapeutic does for others in other scenarios?

<comment><USER9> Yes, dosages vary by your size, weight, gender, stress, and other factors. Part of type 2 diabetes is often insulin resistance, but people with type 1 can also suffer from it as well (although it's not the cause of type 1). Some people even need to use highly concentrated forms of insulin, ie U-500 instead of the standard U-100.

</comment></comment></comment></comment><comment><USER10> This is absolutely amazing!

One thing that's unclear, and perhaps I didn't read carefully enough, is how you're connected to this system.

Do you wear it? Or are you only connected while sitting, sleeping, etc?

<comment><USER11> Read the man page! ;)

[https://openaps.readthedocs.io/en/latest/docs/Gear%20Up/pump...](https://openaps.readthedocs.io/en/latest/docs/Gear%20Up/pump.html)

<comment><USER10> OK, I guess. But I was looking for something in TFA.

<comment><AUTHOR> Hey Vlad - I added some pictures of what I actually wear day-to-day at the bottom of the post. Hope this helps!

<comment><USER10> Thank you!

So really that's not much at all. Impressive. So I'm guessing that there's a strap/pouch for the pump, right? Are the CGM and injection port adhesive?

And for sure, you're a cyborg now ;) With a body area network (BAN). And with much more stable insulin and glucose levels than you could achieve manually. Very cool.

<comment><AUTHOR> Body Area Network! Hahahaha love it, going to use this :)

The pump is actually just in your pocket usually, with a big cord hanging out ready to catch on things hehe. The CGM/pump sets are adhesive but not as much as you'd want sometimes.

</comment></comment></comment></comment></comment></comment><comment><USER12> I'm a bit annoyed people keep calling this an artificial pancreas. The pancreas does a lot more than producing insulin.</comment>


Qutebrowswer: Browser with Vim-like UI - <AUTHOR> http://www.qutebrowser.org/ <comment><USER2> Is it me or is Qutebrower difficult to configure? Trying to change the fonts on Linux is an exercise in sanity.

That being said, I've managed to switch to it from Chromium on Linux successfully. It's definitely the best of the vim-style browsers even superior cVim extension for chrome, which is close but naturally limited (for example, extensions don't load on chrome:// urls so I can't edit settings or scroll naturally without a mouse).

<comment> The-Compiler Could you elaborate a bit? I'm not particularly proud of the current config system, but I'm guessing what gave you trouble is more that handling fonts with Qt is an exercise in sanity... ;)

</comment></comment><comment><USER3> Isn't this just Lynx?

<comment> The-Compiler Have you looked at the screenshots? It's graphical, so, no.</comment></comment>


"Eat More Onions": Desperate and massively debatable medical advice from 1918 - <AUTHOR> https://www.laphamsquarterly.org/roundtable/eat-more-onions <comment><USER2> _In North Carolina, young Dan Tonkel had taken to wearing a bag of asafetida around his neck, in the belief that the stinking extract would protect him. "It smelled to high heaven," he recalled. "People thought the smell would kill germs. So we all wore a bag of asafetida and smelled like rotten flesh."_

For most of human history, we thought that germs were spread by certain odors. So to counteract them, we would often use aromas: this is why plague doctor masks had the horn which was filled with herbs.

EDIT: I meant diseases were thought to be spread by odors, as we didn't yet have a germ theory of disease.

<comment><USER3> And the funny thing is, plague doctor masks were actually fairly effective - it turns out that a beak stuffed full of herbs is actually a pretty serviceable medieval-era substitute for a surgical facemask at preventing you from inhaling aerosols.

<comment><USER4> Yeah, it's kind of funny how we arrived at some of the right answers for totally the wrong reasons. The whole "bad air" concept? Total hokum, but an abundance of fresh air will help control airborne transmission.

<comment><USER5> If you realize that experiment generally orecedes theory, it's completely sensible. Experiments are reproducible, theories are abstract. Making could decisions is more useful than having correct explanations.

<comment><USER6> > _Experiments are reproducible_

Not nitpicking (at least that's not my intent), just adding: Only if you know what the variables are.

This occurred to me because I'm myself an interesting medical case beating even a professor of medicine's prediction, as well as independent ones from various doctors about other things that turned out to be symptoms of the same underlying chronic poisoning issue that I had to diagnose myself, and only then find the right specialist for it. There has been sooo much interesting stuff going on in my body during years of slow recovery (and a few "miracles" that left doctors literally speechless), but I would not be able to say how you could repeat the "experiment". Too little is known about any of what goes on inside me right now, my doctor (researcher at university clinic) has long ago admitted that we left the area of known study-supported medicine behind.

I suspect a few mechanisms based on observing myself that I have no way and no idea how to prove. So I'm of course not certain what I can claim, or what exactly happened, but neither would I know how to repeat my personal experiment even if human experiments were possible. It's just too much unknown territory. And in the end my experiences will all be lost, unfortunately.

An example for something I suspect: Some diseases like the common cold may not always be orthogonal and superfluous. In my case, over the years, I got more and more the impression that it actively helped my body to get rid of what was stored over decades. I suspect that everything is much more intertwined and connected and not separate. One prediction I _could_ make based on this suspicion is that if we were to be able to eliminate mild diseases like the cold completely we would get more serious diseases or other issues down the road. That's not a practical experiment though, maybe some large-scale observational studies can get some hints one way or the other, but it will be too messy and too uncertain for anything even close to a definite proof or disproof.

Another thing I suspect is that even very low level exposure (far below officially allowed levels) to heavy metals has very real consequences - it's just that on an individual basis we are almost utterly unable to show it. We can do it only on a population basis, and we all know how messy that is with all the known and unknown confounders.

</comment></comment></comment></comment></comment><comment><USER7> _Doubt is not a pleasant condition, but certainty is absurd._ [0]

What else would you have done in their position? If you were the health authorities? Do nothing? At its heart, I think this issue is the same one as social science experiments being replicated with lower strength results: We naturally want to handle information as if the truth value is binary, as in mathematical logic and and IF ... THEN statements, true or false. Wouldn't that be wonderful and easy? When the information is imperfect, it seems like we feel justified in targeting our emotions at the offender, but they are doing the only thing they can - acting under uncertainty. Was telling people to eat onions a bad choice, given their choices, and in _foresight_?

As everyone knows from personal experience, if you are giving medical advice, doing scientific research, or making a decision for your startup, the information and possible conclusions are not like in the textbook - they are unclear and messy. You can't wait for the perfect stuff.

[0] Attributed to Voltaire

<comment><USER8> There's a big difference between thinking or saying "I know what I'm doing and there is no risk," when you're clueless, and saying "We are facing a known unknown and have to take a risk." For one thing, if the blowhard eventually comes across the real answer he'll ignore it because he thinks he already understands the situation.

<comment><USER9> The problem is that sometimes you don't have the luxury of being honest with people. Sometimes if you try to give the honest, nuanced picture of the situation, then you just end up making them nervous or you'll sound ridiculous or flip-floppy in one of the ways that normal honest people often sound ridiculous. At the next election, voters'll dump you for a Real Man who will 'talk straight' to them.

I would never want to be a politician.

<comment><USER8> Facing the ethical reality, if your team doesn't want to take a certain risk (based on their estimation of their own risk-tolerance), you're not lying for their own good if you convince them that the risk isn't there. If they _do_ want to take the risk, then you can inspire a pretty cool culture by making the importance of the task at hand clear to everybody.

<comment><USER9> If you are able to build a team, then you often have the ability to judge your hires based on their ability to accept that:

\- we live in a world of tradeoffs

\- we live in a world of uncertainty

\- order and trust are far more fragile than chaos and discord

This is not so when working with a constituency.

</comment></comment></comment></comment></comment><comment><USER10> Asafetida today is probably best known for its use in Indian cuisine.

<comment><USER11> You're getting downvoted for some reason. You're 100% correct.

In Indian cuisine it's used as an umami enhancer. Usually with turmeric in vegetable dishes - especially lentil curries like dal and sambar but also those based on potato and cauliflower.

Kashmiri cuisine famously uses it in Rogan Josh.

</comment></comment><comment><USER12> I still believe eating more onions is a great idea because of the fructooligosaccharides (prebiorics that good gut bacteria feed on).

<comment><USER13> Unfortunately there is not enough evidence that such prebiotics help with anything.

Other than increasing flatulence that is.

</comment></comment><comment><USER14> Seems down, here's a mirror: [https://web.archive.org/web/20180918143108/https://www.lapha...](https://web.archive.org/web/20180918143108/https://www.laphamsquarterly.org/roundtable/eat- more-onions)

</comment><comment> the-dude From 1940 : [https://www.smithsonianmag.com/arts-culture/a-wwii- propagand...](https://www.smithsonianmag.com/arts-culture/a-wwii-propaganda- campaign-popularized-the-myth-that-carrots-help-you-see-in-the-dark-28812484/)

More carrots, not onions.

</comment><comment><USER15> No need for time travel here...

I currently live in the south of Morocco and this is exactly the kind of advice I am given here constantly. My SO went through _months_ of dietary restrictions based on such advice; got her to hospital 2 weeks ago and today the lab results are in: bacterial infection. We are looking forward to the first proper dinner in a very long time.

My personal highlight on local advice I was given: "Keeping a tortoise in your house helps with asthma. My cousin has asthma and when it is really bad, he comes back to his parents' house and after a few days it is much better!" (That house is in a very small mountain village with very clean air, he lives in a very big city full of cars and he does not dare to smoke anywhere in his home village or his parents' house lest his parents see that.. go figure.)

</comment><comment><USER16> I'm at home for the past few days with a barely breathing nose, a sore throat and a headache. Humanity is about to get people travel around the Moon, we have self-driving cars and AI, but FFS(!), can someone create a pill that would kill a common cold/allergies? It drives me nuts that we don't have a solution for such a popular problem. I think I tried everything, but the recovery time is always around 7 days no matter what you do.

<comment><USER6> Incidentally, I just wrote another (pretty long) reply mentioning just that. Based on my own very unusual medical history I _suspect_ that _maybe_ you should not want that. Of course I know nothing for sure at all, it's just that observing my own healing process I was pretty much force to conclude that at least _sometimes_ there _may be_ more to a cold than just "a cold", that it may (can sometimes) have an effect that is not just "I happened to be sick for a week", that it actually does something. Even if my own very personal reasons and thoughts turn out to be wrong, what about training of the immune system ("training" is not a good word because what does it even mean, but there must be _some_ feedback effect, surely)? I snot having any little issues at all for decades really good? I think there are endless feedback loops and it's all a lot more mixed and complex. I would be skeptical that such a magic pill would be net positive.

<comment><USER16> Yea, while I wish I a had magic pill, I have thought the exact same thoughts just earlier today. But anyways, shoot me a message if you find that pill by any chance ;)

</comment></comment></comment><comment><USER17> Food Chemistry: "Anti-influenza A virus effects of fructan from Welsh onion (Allium fistulosum L.)" ( 2012 )

[https://www.sciencedirect.com/science/article/pii/S030881461...](https://www.sciencedirect.com/science/article/pii/S030881461200653X)

</comment><comment><USER18> It worked for Stanley and Zero at Camp Green Lake</comment>


NTT Internet BGP Visualization - <AUTHOR> http://as2914.net/#/

<comment><USER2> Isn't this just posted yesterday? [https://news.ycombinator.com/item?id=10177835](https://news.ycombinator.com/item?id=10177835)

<comment><AUTHOR> Whoops - yes sorry. I managed to copy/paste the /#/ at the end of the url so I assume HN didn't pick up the dupe.

</comment></comment><comment><USER3> The page doesn't load for me, claiming that I don't have WebGL. chrome://gpu confirms that I do. Is anyone else having this issue?

<comment><USER4> I think it might be down-isn -- HN hug of death. It's a pretty heavy web app.

<comment><USER5> It loads at 100 Kb/sec here in Amsterdam, but does not seem down.

I am not familiar with the GPU error. So far most say the best viewing experience of this app is with Chrome.</comment></comment></comment>


Show HN: Mowned – A Journey to Phone Nostalgia - <AUTHOR> https://mowned.com/ <comment><USER2> A very apt name, I'm at a party and just lost about an hour revisiting old phones and chuckling at how the introduction of the iPhone changed the status quo immediately.

<comment><AUTHOR> Thank you! Sorry if ruined your party :P

Indeed, Apple in general is setting the trend in the industry.</comment></comment>