Opaleye's sugar on top: SQL in the type system - <AUTHOR> http://ren.zone/articles/opaleye-sot <comment><USER4> > That is, as an example in our case, we can't expect that a Haskell data type > that today maps perfectly to a SQL row will continue to do so after any of > the two is modified.

But we can and do if we use the compiler to dynamically generate code. For example, with F#'s SqlClient (a type provider) [0], types are generated based on queries, correctly mapping database columns (including nullable ones) to fields on types. If you change the queries, or tables (and you are doing 'select *'), the types get updated automatically. This seems like a better approach.

This is also similar to how popular popular db access approaches in dynamic languages such as ActiveRecord in RoR work. Tables are inspected at runtime, and getters, setters and utility methods are generated based on that.

I imagine this is also possible in Haskell via Template Haskell, which the author dismisses as too complex/fragile, though I don't know Haskell well enough to be sure.

[0] - [http://fsprojects.github.io/FSharp.Data.SqlClient/](http://fsprojects.github.io/FSharp.Data.SqlClient/)

<comment><USER5> Do type providers provide you with semantics difference when type errors occur? If not (e.g. they don't tell you about arity mismatch citing relevant part of awl query), then they are inferior to the method of expression of queries in type level.

</comment></comment><comment><USER6> Honestly none of the statically typed sql generators (Opaleye included) really tick all the boxes; all are lacking in one way or another.

Here's a breakdown of the leaders of the pack on this front[0]

Haskell

1) Opaleye[1]: composable and prevents invalid sql, but no join support (simulated via sub selects), Postgres only, and tough syntax to parse.

2) Esqueleto[2]: composable, readable, supports joins, but Postgres only, and the DSL can't/doesn't prevent invalid sql (which is, IIRC, one of the reasons why Opaleye came into being).

Scala

1) Slick[3] myriad databases supported (Oracle and SQL Server require non-free license), join support, fully composable (really, king of monad hill), and elegant syntax (until you `groupBy`/`sortBy` and then enter unreadble tuple_.1, tuple._N soup). Also, grouping requires flattening result set via min, max, sum, etc. aggregate function so not possible to return tuple representing say, a User, when grouping. Suggested workaround is to group on the client (and send a million rows over the wire to app server, ok o_O).

2) Squeryl[4] myriad databases supported (all free), join support, sql-like syntax, but lacks compositionality of aforementioned and relies on runtime reflection to make the DSL go.

Microsoft

LINQ to SQL/Objects myriad databases supported (not sure of driver licensing), excellent sql-like syntax, and type providers straight other worldly, but lacks compositionality and is tied to Windows (until *nix support lands).

[0] There are likely (many) others but these are the statically typed ones I'm aware of. Feel free to add others, curious to see what's out there (e.g. OCaml must have something)

[1] [https://github.com/tomjaguarpaw/haskell- opaleye](https://github.com/tomjaguarpaw/haskell-opaleye)

[2] [https://github.com/prowdsponsor/esqueleto](https://github.com/prowdsponsor/esqueleto)

[3] [https://github.com/slick/slick](https://github.com/slick/slick)

[4] [https://github.com/squeryl/squeryl](https://github.com/squeryl/squeryl)

<comment><USER7> Some corrections/comments/questions:

> Opaleye ... no join support (simulated via sub selects)

This is true for exactly one reason: despite being raised frequently, nobody has ever been able to demonstrate any performance difference between subselects and joins (in Postgres)! As soon as someone does, they should file an issue ([https://github.com/tomjaguarpaw/haskell- opaleye/issues/](https://github.com/tomjaguarpaw/haskell-opaleye/issues/)) and I'll add joins forthwith.

> Opaleye ... tough syntax to parse

What do you mean by this? The Haskell syntax of Opaleye, or the generated SQL?

> Esqueleto ... Postgres only

You're incorrect about this. From your Esqueleto link:

"It has many kinds of backends, such as SQL backends (persistent-mysql, persistent-postgresql, persistent-sqlite) and NoSQL backends (persistent- mongoDB)."

> Esqueleto ... can't/doesn't prevent invalid sql

But you're right about this.

</comment></comment><comment><USER8> I firmly believe that teams working in static languages do not easily transition to dynamic languages, and vise versa, yet when working with SQL that is what we're constantly asking people to do, because SQL is either less static than C# or Java or more static than Python or JavaScript. It's this weird, bastard of a language that sits halfway in between, with no good way of unit testing it because most operations are stateful [0].

Most SQL engines include a static verifier of some kind, but it ranges from nearly non-existent in MySQL's case to so-pedantic-it-hurts in Postgres' case. Even worse are the ones like MS-SQL that are static in some regards (you can't usually submit a stored procedure that references non-existent tables), but dynamic in other regards (but non-existent columns in those tables are fair game!).

Personally, I'd prefer a lot more static checking. This starts off ok, but I need more. This appears to be Postgres only right now. I think a static checker for vendor-specific SQL is a key component for getting people off of Oracle or MS-SQL. I've seen tons of database conversion projects die on the vine because of the issues with translating vendor-specific extensions. We need a "VM for SQL", some way to write-once-run-anywhere, and ANSI SQL is insufficient. I mean, have any vendors actually gone beyond SQL-92? There have been four newer versions since then.

[0] I mean, that's not a surprise, that's the entire point, it just makes good unit testing very hard.

<comment><USER9> >I mean, have any vendors actually gone beyond SQL-92?

Yes. Here's a pretty good summary presentation (it says it's Postgres-focused, but it provides adoption data for the major vendors)[0] and the HN comments[1].

What we tend to see (I speak from a position as a BI consultant - I get to see lots of companies' database infrastructure) is that adoption of new SQL constructs is mostly limited by the developers, and in some cases IT departments who won't upgrade SQL server software.

New SQL being limited by developers comes in two flavors, crusty DBAs and do- it-all-in-the-app-layer developers. The second type tends to be more common among demographics similar to HN.

[0] [http://www.slideshare.net/MarkusWinand/modern- sql](http://www.slideshare.net/MarkusWinand/modern-sql)

[1] [https://news.ycombinator.com/item?id=9018129](https://news.ycombinator.com/item?id=9018129)

<comment><USER8> That's a pretty abysmal report. You basically can't count on any of those features to be available across databases.

You are correct about the fear-of-SQL amongst most application developers.

<comment><USER9> The target is moving. Your question: "Have any vendors moved beyond SQL-92?" The answer is a clear yes. The question was not, "Do all major RDBMSs support the same subset of the SQL standard?"

The implied concern with the new question is portability of code across databases. This is a red herring based only on some snippets of SQL syntax and features.[0]

Even if the SQL were identical, no major RDBMS has as its selling point that it only supports the SQL standard. Additionally, even with identical SQL, the implementations in each RDBMS are different enough that logically equivalent code would still need to be rewritten.

One example: There is nothing in the SQL standard about optimization of queries. One place this shines through is in Postgres CTEs vs MS SQL Server CTEs (I cannot speak to other implementations). In Postgres, a CTE is an optimization boundary - predicates from the query utilizing a CTE will not be pushed down into the CTE. The entire CTE is executed each time it is referenced. This is in contrast to the behavior of sub-queries, which do support predicates being pushed down into them. In SQL Server, CTEs are just an in-line view definition and do support predicates being pushed into the CTE from the outer query. Any codebase converting from MS SQL Server to Postgres would need to have every instance of CTE use evaluated for performance.

[0] The previously linked deck highlights only some advanced excerpts of the SQL standard. The venn diagram of supported SQL constructs is much more overlap than exclusive.

</comment></comment></comment></comment><comment><USER9> > Reading, writing and maintaining hand-written SQL is hard and error prone.

I see this attitude a lot on HN, often whenever any ORM comes up, and it's often taken as axiomatic.

I'm honestly curious to hear people's opinions about what makes SQL so much more difficult to use correctly than other programming languages or environments. I come from a background in BI and data warehousing, so I'm pretty comfortable with SQL as a second language, as I like to call it.

Here are a few things I understand as unique in SQL, some of which clearly do add unique difficulties:

* Everything not a SELECT is stateful - unit testing becomes difficult

* Syntax/semantics are far from most "normal" languages (not C-like, not similar to shell scripting, not OO, not functional, verbose in a style similar to COBOL, the hated)

I, personally, do not find large SQL codebases particularly difficult to work with correctly or understand. Perhaps this is a combination of ignorance and Stockholm Syndrome since most of my experience is in databases and heavy SQL work. I'd like to understand better why the attitude in the excerpt I quoted seems so common.

Ninja edit: Additionally, I find a lot of power and expressiveness in the relational model. Again, perhaps because of the focus of work I do I find SQL indispensable and very easy to use for both exploratory programming and data analysis, as well as robust programming e.g. for ETL processing. Note: I still use ETL tools and frameworks, but this is not to remove SQL from the equation, but for the better dependency tracking and process monitoring.

<comment> T-R SQL is incredibly low level

\- Modelling Sum Types requires giving up correctness guarantees, performance, or both.

\- It's not expressive enough to get performance or abstraction - I can't communicate "this is a one-to-one relationship", "this is append-only", "this is associative", or "these things commute" in anything but comments. And my co-workers need to remember to make those joins, and think about how they can use that information to hand-optimize, because the optimizer sure as hell isn't going to do it for them.

\- There's no abstraction/composition of anything at lower than a full query granularity, so everything needs to be inlined and repeated everywhere - <USER2> makes conceptually small changes, like going from single- to multi-column primary keys or vice-versa, require rewriting practically every view/query.

\- Some optimizer WATs are required by the spec ('where' clauses can be propagated down the AST even past another clause that does type refinement; CTEs always materialize the result set and act as optimization walls), others may be implementation dependent (At least in Postgres, "Union All", instead of acting like a simple stream concatenation, more often than not materializes the whole result set and pages it out to disk - your 0.2ms query now takes 2 seconds). SQL is "Lazy when the stars align" and optimized by "this won't break things in the trivial case" \- most effort in non-trivial queries is spent trying to convince the optimizer not to hurt you on a whim. Don't get me wrong, the devs do absolutely impressive stuff with what they've got - <USER3> quirks are clearly what needs to be done to compensate for the spec, and the spec can't change for compatibility resons - but it doesn't make it easy to work with.

\- Things like missing a column in a join clause (like when changing that primary key) cause significant bugs that don't actually throw an exception/type error anywhere - they just change the size of your result set. This could be completely fixed with type-level literals.

\- Types are internally inconsistent, and supplied functions are pretty much ad-hoc "we thought this might be useful". Type conversions regularly involve first converting to a string or wrapping in a nested query.

\- The syntax is pants-on-head ridiculous for anything non-trivial, making education difficult and maintenance tedious. (especially window functions - SELECT a, b, LAST_VALUE(b) OVER (ORDER BY c ROWS BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING) AS x).

The problem, though, isn't just the amount of code and maintenance issues this creates - it's the sheer amount of information that everyone on your team who touches the database _needs_ to know and not overlook _just_ to not create subtle bugs and significant performance issues. And all this knowledge is completely non-transferrable.

SQL is so bad that standard practice is just to not do anything on the database unless you have to; eating the connection overhead, adding yet another cache, and having a layer of wrapper functions are just considered the cost of doing business, leading a lot of people to think SQL is perfectly sufficient for what it does.

<comment><USER9> I do truly appreciate the critique you've offered, as it has some well-thought out objections to the language.

I don't want to get into a back and forth on how to deal with the specific issues - they're good food for thought, but I think it wouldn't lead to a productive conversation.

I would object that SQL is actually incredibly high level, though its abstractions differ from the typical ones seen in other programming languages. As a declarative query language, I can describe a join between two arbitrary (no need to do anything besides have the tables exist) tables and the query optimizer will do a very good job of choosing among several different algorithms to perform that join for me. Without a thought to any statistics of the data, the query is optimized appropriately, including the construction of a temporary index if that is the best way to compute the join.

Or, transactions in general - ACID guarantees are maintained with a simple transaction - almost no boilerplate, just saying where it begins and where it ends with some options for specific behavior, and the transaction is guaranteed on arbitrary data structures without any other code necessary.

I won't go into the data consistency guarantees you can make just by defining a couple of foreign keys and constraints (performance aside - these can be optimized - this would be awful to put together by hand in a project)

These are some of the abstractions in SQL which are absurdly high level compared to doing something similar in another language. Several of your bullets also support that it is a high level language, e.g. 4 "others may be implementation dependent" \- this is not a statement ever made about assembly for example.

SQL is, at the end of the day, a query language built around relational algebra, already an abstract topic, and implemented on arbitrary hardware, operating systems, filesystems, and so on. It's not got a lot of high level concepts that exist in other languages, sure, but it's got a lot of stuff built in that would be a bear and a half to implement on your own. Its high level concepts are in general very orthogonal to those in other languages.

Again, I'm not disagreeing with your bullets, and I appreciate the time you took to reply and your points are exactly the sort of thing I was asking for. I just think that you're ignoring some of the power in it for want of the power of constructs you're more familiar with.

<comment> T-R It's definitely relevant that my complaints are from a Haskell perspective (as this is a Haskell thread). If I'm working in just about any procedural/OOP language, sum types are a completely foreign concept. If I'm working in PHP, I don't expect a consistent API. If I'm working in a strict language, I don't expect to be able to abstract my data model away from how I loop over it in memory. If I'm used to anything without some support for dependent types, I just assume that an empty list, or a list with too many entries couldn't possibly be detected at compile time. The high level constructs it does have are strictly less powerful, largely as a function of not being composable/consistent and certainly not as polymorphic as the kinds of things in Foldable/Traversable, though certainly better than writing your own for- loops.

The thing is, these are practically all you do in SQL, so it's pretty frustrating that, when working with it, so much time is dedicated to dealing with these _solved_ problems. They're the reason you can't import a "votes" or "comments" package to your database, and why being a database expert is such a niche, specialized, and lucrative position - because so much knowledge isn't captured in the language, or the compiler, or libraries (even though it quite feasibly could be), but just spread by books and blog articles. It's why building complex things on relational databases is so hard - the level you're working at is strictly limited to "what keys do I join on to get the result set I want" and "how do I make this only loop once" \- it's not inherent in the relational model/relational algebra, it's strictly a problem with SQL.

To add, as a declarative query language, it's worth also comparing to things like Prolog/Datalog. Prolog certainly doesn't get you all of the things I mentioned, either (e.g., no dependent types), but it is a much higher level of abstraction - you can describe things like "this is a one-to-one relationship" at a high level. The flipside is that, to write performant queries, you need to understand the Warren Abstract Machine, but because of its consistency, that's a significantly lower barrier to entry than trying to understand a specific database's optimizer implementation, or the arbitrary decisions in the SQL spec, and the knowledge there is actually transferrable.

</comment></comment></comment></comment><comment><USER4> > HList has some properties that are very interesting to us. To start with, > not only we can store an arbitrary number of elements of different types, > but we can also know statically—that is, at compile time—both the number and > types of those elements.

I didn't know Haskell could do that - impressive.

<comment><USER10> You can do it in Scala too (cf. [https://github.com/milessabin/shapeless/wiki/Feature- overvie...](https://github.com/milessabin/shapeless/wiki/Feature- overview:-shapeless-2.0.0)).

</comment></comment><comment><USER11> I wonder if something similar would be useful for mapping between application models and web services for those models. They're probably different enough that the most useful part would be the idea of modeling the types involved in the operations, but not much else.</comment>


Phil Schiller Inital Response to MBP Criticism - <AUTHOR> http://www.independent.co.uk/life-style/gadgets-and-tech/features/apple-macbook-pro-new-philip-schiller-interview-phil-iphone-ios-criticism-a7393156.html <comment><USER2> It doesn't seem like there is even an understanding of the criticism based on his response in the article.

Let me spell it out explicitly:

The criticism is that this is a Pro machine. Pro people care about performance and features.

The decision to optimize for thinner and lighter at the expense of other useful features is the criticism. The weight and size were fine before. I don't care. I'd be fine with bigger and heavier too. All I care is that it fits in a normal size backpack / travel case.

As a photographer I would need have an SD card reader now and the vast majority don't come in USB-C. If I already had a reader I would now need a dongle to convert it. That's more hassle and more things to lug around. I already need to carry several bags worth of studio gear, the less I need to carry the better.

In terms of video, there really isn't any compelling reason to upgrade until Kaby Lake is out. The increased 4K encoding and decoding is quite significant. It would have been nice to have the MBP come out earlier, that way another MBP could be released shortly after the Kaby Lake release. If it takes another 1.5 years before another MBP then it would be really far behind the best possible hardware.

In short, people who buy the MBP want a Pro laptop, not the Air.

Honestly, based on what I'm seeing right now, professional software developers, photographers, and videographers seem to be ignored.

I switched to Mac when Apple started using Intel. Based on what I'm seeing now, I'm exploring switching back to Windows.

If I'm not your target market anymore, so be it. I can appreciate the business reasons to concentrate on making money. But don't delude yourself into thinking you're serving Pro or creative users anymore.

<comment><USER3> > The criticism is that this is a Pro machine. Pro people care about > performance and features. > The decision to optimize for thinner and lighter > at the expense of other useful features is the criticism. The weight and > size were fine before. I don't care. I'd be fine with bigger and heavier > too.

I mean, that's a bit of a weird criticism to level at Apple, isn't it? Making things thinner and lighter has been Apple's MO even in the Pro Line for more than a decade. I remember when the 12" PowerBook G4 came out. It was hailed as breakthrough product for road warriors. It fit a 12" screen into a 4.6 pound frame. Today, the 15" is even lighter than that. Do we miss stuff like the optical drive enough to want to go back to 4.6 pound laptops that only fit a 12" screen?

Obviously, even Pro users care about size/weight. If they didn't there would be no point making the 13" model.

> All I care is that it fits in a normal size backpack / travel case.

So you don't care about the size/weight of the laptop, but the size/weight of the dongles is a deal-breaker? And you'd rather have everyone pay for ports only a few people need than to pack some dongles in one of your several bags?

> In terms of video, there really isn't any compelling reason to upgrade until > Kaby Lake is out.

People would've flipped their shit if Apple had skipped both Broadwell and Skylake.

<comment><USER4> >So you don't care about the size/weight of the laptop, but the size/weight of the dongles is a deal-breaker? And you'd rather have everyone pay for ports only a few people need than to pack some dongles in one of your several bags?

I'm not the OP, and for the most part I agree with your take, but here, I get it. Things like dongles are easily lost or broken when you most need them out in the field. When you're busy trying to do something, you don't want to be scrambling trying to find a dongle while you're missing shots -and then fifteen minutes into a search for an adapter you remember you might have left it in the car...

I mean, at the airport, I can have my ticket right in my pocket, but damnit if I can't find which pocket it's in.

</comment></comment></comment><comment><USER5> I think Apple design has an anorexia thing going on. They are making things thin for thinness sake.

If Apple made dedicated "pro" cameras I think they would make them so small you couldn't hold them without your finger getting in the way of the lens and ditch the memory card in favor of wifi "because it's the future".

(Please resist the urge to point out that pro photographers sometimes use iPhones cameras.)

<comment><USER6> _Apple design has an anorexia thing going on_

SNL nailed this a decade ago. Presenting the iPod Invisa: [https://www.youtube.com/watch?v=plx69SIvgWI](https://www.youtube.com/watch?v=plx69SIvgWI)

</comment></comment><comment><USER7> "Is it inconsistent to keep the 3.5mm headphone jack as it's no longer on the latest iPhone?

Not at all. These are pro machines.

The new Pros have no SD card slot for a camera memory card. Why not?

you can use a physical adaptor if you want"

I mean most audio pros were using external soundcards since like forever, however imaging pros are now f'd in the a with their SD cards and USB-A cables. Sure this can be addressed with adaptors easily, but they are the ones who travel the most, and need the least number of dongles.

Schiller's (Apple's) argument is super weak.

They have made the best "pretend-a-pro at Starbucks" machine.

Now with emoji bar!

</comment><comment><USER8> _" It's part of our thinking about where to take the notebook next. Others are trying to turn the notebook into the tablet. The new MacBook Pro is a product that celebrates that it is a notebook, this shape that has been with us for the last 25 years is probably going to be with us for another 25 years because there's something eternal about the basic notebook form factor."_

This is interesting. I would hope that sometime before 25yrs from now we have reliable enough voice recognition to get rid of the physical keyboard, good enough VR/AR to make a 3D UI (along with a popup VR keyboard for the occasional word that needs to be manually typed out or for when working in libraries). House it all in a pair of AR glasses attached to a battery/CPU/RAM/SDD in a backpack (replacing the laptop in the backpack of today). Seems something like that should be the holy grail of personal computing, achievable within 10-20yrs, and really Apple's wheelhouse more than any other.

</comment><comment><USER9> Duplicate: [https://news.ycombinator.com/item?id=12855252](https://news.ycombinator.com/item?id=12855252)

Actual title: Apple's Philip Schiller talks computers, touchscreens and voice on the new MacBook Pro

(shortened to "Phil Schiller Discusses the new MacBook Pro" in first post)

</comment><comment><USER10> "But many users have setups with studio monitors, amps, and other pro audio gear that do not have wireless solutions and need the 3.5mm jack."

Any user with "studio monitors, amps, and other pro audio gear" is not using the 3.5mm jack. I dabble in music production (i.e. I'm very much a beginner) and I use an USB audio interface. The built-in DAC, while better than most PC's, is not very good.

How does Schiller even pretend that this is a valid justification for the 3.5mm audio jack on the Mac but not on the iPhone?

</comment><comment><USER11> I thought thinner and lighter is for the MacBook Air. I would much prefer a slightly thicker device with more power. The 16 GB restriction makes no sense either.

<comment><USER12> That has already been explained so it does make sense:

[https://www.reddit.com/r/apple/comments/59yrxg/the_true_reas...](https://www.reddit.com/r/apple/comments/59yrxg/the_true_reason_the_mbp_doesnt_come_with_ddr4_or/)

Since I'd like 32GB in my next mbp, I'll be waiting for the next rev

<comment><USER13> It makes "sense", until I see that a company like Lenovo sells a laptop with up to 64GB RAM [1]. The difference is that Lenovo uses Intel Xeon chips in the higher end models. Apple could make a laptop with that much RAM (and all the ports everyone wants, and a proper keyboard), they're just choosing not to. Presumably because then they couldn't say it was thinner & lighter.

[1] [http://www3.lenovo.com/au/en/laptops/thinkpad/thinkpad-p- ser...](http://www3.lenovo.com/au/en/laptops/thinkpad/thinkpad-p- series/P50/p/22TP2WPWP50#tab-tech_specs)

</comment></comment></comment><comment><USER14> I made a note of the minijack thing.

Are there any wireless music protocols that allows for delay-less playing of audio? My bluetooth speaker has about half a second, maybe one second delay. Airplay has a delay as well. I don't know about the new airpots though.

I think Apple might see their notebooks and iPads as devices people will watch movies on somewhat seriously, and therefore will need a delay-less way of listening.

</comment><comment><USER15> Quote from the article:

And we are proud to tell you that so far our online store has had more orders for the new MacBook Pro than any other pro notebook before.

<comment><USER16> Could it be that it was 527 days since the previous update which is, by a wide margin, the longest delay between MBP updates ever?

[http://buyersguide.macrumors.com/#Mac](http://buyersguide.macrumors.com/#Mac)

<comment><USER17> I think it's even more likely due to the fact that 4 out of 5 laptops they sell are labeled "MacBook Pro" \- including the MacBook Air replacement.

If Chevy named the majority of their cars Malibu (1/2 ton truck), Malibu (3/4 ton truck), Malibu (2 door sports car), Malibu (4 door electric sedan), Malibu (4 door full-size sedan) then they would have the largest amount of Malibu's sold ever too.

<comment><USER18> Well spotted. No doubt in some secret Gattaca-esque white room at infinite loop there are a bunch of carefully dressed project executives in damage control mode.</comment></comment></comment></comment>


What should or shouldnt I do to stop spam on my blog? - <AUTHOR> http://blog.karolzielinski.com/what-should-or-shouldnt-i-do-to-stop-spam-on-my-blog <comment><USER2> You can also install a honeypot. Some text links that your human visitors don't see but that bots do, and that way trap malicious bots which do not respect your robots.txt file.

There is an outgoing project: Project HoneyPot, which uses honeypots installed among their members to detect bots to build a database of malicious bots which can be consulted by their API or their plugins. They even report if there is evidence of Spam being sent as a consucuence of the bot visit.

They have plugins for wordpress among others.

<http://www.projecthoneypot.org>

<comment><USER3> Are honeypot strategies still effective? They talk about using hidden form fields here: <http://www.rustylime.com/show_article.php?id=676>

...but they add a disclaimer: "We are no longer using this method as it, after more than a year of successful use, seems to be beaten regularly now."

</comment></comment><comment><USER3> "4. Stop spam trackbacks.." Don't forget to consider using rel="nofollow" (which most weblog software marks reader-submitted links by default)... <http://en.wikipedia.org/wiki/Spam_in_blogs#nofollow></comment>


Netflix assets server certificate revoked, causing the site to break on Chrome - <AUTHOR> Looks like Netflix's certificate has been revoked for nflximg.net, which seems to be their CDN.
https://www2-ext-s.nflximg.net/pkg/4.2.8/web/233e8174/css-secure/3/01501701602200001f0180a10a001902001b03204403a02105018f10b01a03917f0a2180181182/css/z
Whoops. <comment><USER2> I think this is a side effect of the revocation of the old 1024-bit VeriSign Class 3 root.</comment>


Infoliberalism, or how the Internet can replace the traditional political order - <AUTHOR> http://infoliberalism.info/ <comment><USER2> This is simultaneously way, way too much and not enough at once. The 'political part' that covers justice and supposedly replaces governments and courts seems to only address fraud and deception, and uses an elaborate mixture of organizations and computer systems to solve a problem people can mostly just work out on their own...

And then it completely ignores the state's monopoly on violent retribution, which even libertarians support. AFAIK only some flavors of anarcho- primitivism reject that and this plan has way too much infrastructure for that.

<comment> loup-vaillant May I ask what is wrong with the _state's monopoly on violent retribution_? What are the alternatives? What do you think would happen if there is _not_ such a monopoly?

The way I see it, we don't have much of a choice. I'd rather try and ensure that the state is actually benevolent and competent. Once we guarantee that, giving it monopole over violence should be cool.

As for building a good state, I'd start by trying democracy. Not the "representative" government we have now, but something where the people would, say, directly vote for their laws. Like ancient Athens, except without slave and with gender equality.

<comment><USER2> I don't think anything's wrong with it, and I'm not aware of any alternatives that would be worth the cost. If the OP is planning on replacing government he'll need to replace that state function within his system and he's given no hint as to how he'll possibly do that.

<comment> loup-vaillant Oops, my bad. I assumed the negative connotation in "monopoly on violence" was intended. Maybe we should talk about the "enforcement mechanisms" or something?

</comment></comment></comment></comment><comment><USER3> I don't believe we will see something like an infoliberalist state in the next 5 or 10 years, but it's interesting that tech is increasingly making those ideas feasible.

I'm the founder of a startup building a modern forum platform with no fixed administrators. Instead, members build a network of trust by agreeing with (liking) each other's posts, and the top most trusted members become moderators. Check out <http://www.iroquote.com>

Also <http://www.reasonwell.com> is a tool for efficient online debates on policies.

It would be nice to see other similar projects related to politics. Please share some links if you know more.

</comment><comment><USER4> I'm struggling to see how this is different (or better) than Anarcho- capitalism or other voluntary systems?

Technically the private systems within an ancap society could be implemented in a similar technology-based fashion, without having to disregard private property laws.

<comment><USER5> He actually does say it:

> The title of infoliberalism that I recently gave to this theory expresses > its similarity of logic with some radical liberalisms like agorism (see the > new libertarian manifesto) or anarcho-capitalism, of which it would > constitute somehow an effective method of realization; with the difference, > that it is rebuilt on a new foundation : instead of the postulate of private > property (but while most often respecting it), infoliberalism is built on > the postulate of communication freedom, which only needs proper software on > the Web for developing all its logical consequences up to rebuilding the > whole political order.

In other words, this still conveniently ignores the fact that we're still meatbags who live on tracts of land, so I don't know.

</comment></comment><comment><USER6> Please hire a copyeditor. Please.

<comment><USER5> He's French.

</comment></comment><comment> guard-of-terra I no longer believe that any of our actions can turn anything for the better.

Our only hope is discovering FTL and leaving this doomed planet for good.

<comment><USER7> And in the several decades until then, you will be...

<comment> guard-of-terra Suffering from excruciating mental pain from within?

</comment></comment></comment><comment><USER8> Hello. As author of this theory I'm joining this discussion.

"to only address fraud and deception" Well, no, there is more than this : the power structure I described, distinguishes several categories of power that can be delegated to different people in a systematic way, so that it is an effective organizational structure to deal with different issues: \- systems of qualifications (diplomas) \- research on legislative issues (on environmental and other issues of right and wrong and which rules would be needed) \- attribution of financial resources for public interest operations (though it could be feared too weak as initially relying on donations, for standing competition with state expenses... if we forget that states are currently running to bankruptcy) \- Financial investment decisions (granting credit in someone's name) \- Judgment in difficult conflicts, or where one is not directly involved in ...

"uses an elaborate mixture of organizations and computer systems to solve a problem people can mostly just work out on their own"

More precisely, it rebuilds an organizational structure through an efficient use of computer systems. The point is to address those problems that are involving too many people (and/or people whose contact would otherwise not be under hand), which for this reason could not yet be just worked out by people on their own. And do it by systematically putting together the needed information which will finally make it possible for people to apply their own free judgment and action, possibly through delegates when needed, for solving the problems.

"And then it completely ignores the state's monopoly on violent retribution" What do you mean by "ignore" ? I focus on a large category of problems and how they can be resolved independently of the presence or absence of any violent retribution system; and that this is a so important quantity of things that the effects of these "soft" solutions will finally turn out to be heavier than the ordinary use of force by democratic states (well the case of non- democratic countries will be harder but...), and will ultimately absorb that use of force in it.

Some discussions implicitly assume the old list of political theories as the only available alternatives, thus are made obsolete by this proposition of another solution. I don't feel concerned with the question "state monopoly of force or not" since my proposition develops on another level that makes the question of force somewhat irrelevant. Namely, it would first focus on handling a large range of problems that I would qualify as indeed political but without disputing or requiring interaction with the current state power, as these are political problems of a kind that does not enter the category of problems that the state ever tried to manage: too small and not formal enough problems to ever reach any bureaucrat's desk, but of still quite real and heavy importance once summed up, relativizing as anecdotal the question of what to do with state force. Need examples ?

To talk about "enforcement mechanism" : I offer one that can be effective without need of force. Because it is an enforcement on money, but money is a mere information (a social convention), which can be "forced" by the mere play of information interaction without need of any physical force. See for this the beginning of my text on money.</comment>


Google's Greatest Strength May Be the Luxury of Failure  - <AUTHOR> http://blogs.wsj.com/cio/2013/05/17/googles-greatest-strength-may-be-the-luxury-of-failure/

<comment><USER2> "The lesson may be that a broad focus on innovation and solving big problems leads to resiliency."

That would be an interesting conclusion if there was a good reason to believe it, but the article didn't make much of a case. How many of Google's off-the- wall projects are contributing to their 30% year-over-year quarterly revenue growth? Most of the projects mentioned were either market failures or haven't been released yet. Android was clearly a success, but it wasn't a great example of innovation: it was basically a clone of a successful existing product.

There's probably a more prosaic explanation for Google's success relative to Facebook. Both companies make most of their revenue from advertising, but Google developed AdWords, which leveraged Google's search infrastructure to became an essential piece of infrastructure for the buying and selling of ads. It's hard to name any other company that got rich off of web ads besides Google. Google is entrenched in the fabric of the internet, while Facebook is an upstart that's primarily just a website, like Yahoo was 15 years ago. At that time, Microsoft was the giant that owned the critical infrastructure, and they were doing very similar things as Google is now: Microsoft created MSN to compete with AOL and Yahoo; Microsoft leveraged its infrastructure to crush a threat from an upstart competitor -- Netscape. Building out, as much and as fast as you can, seems to be the winning strategy when you are in a position of overwhelming dominance as a result of owning essential infrastructure.

The "Luxury of Failure" is the actual lesson here. You get the luxury of failure when you own a revenue stream that's big and entrenched enough that you have the luxury to do essentially anything you want, even lose money. It's hard to compete against that.

<comment><USER3> Microsoft has the luxury of failure also, but when they tried to compete with Google they failed. Microsoft are in the same markets that Google makes a huge amount of money from and yet they failed on most fronts.

I think the safest way for Google to make money would be to not innovate or create any off the wall projects, and then just return the money the money to shareholders through dividends or share buybacks.

Just looking at the current stock price of Google $909 and Earnings per share of $33, this means that IF Google returned the entire earnings to shareholders it would take 27 years for the shareholders to get their money back and THEN after this 27 years they would start to get a return on their investment. This assumes no growth, and Google has grown significantly but there is no guarantee they will grow in the future. Even if they do grow significantly it will still take a very long time to get your investment back.

There are unknowns that could completely disrupt Google's business models for example what if all search became voice based (siri-like) with better AI. Or what if a competitor develops much better AI capabilities into their search.

<comment><USER2> >> Microsoft has the luxury of failure also, but when they tried to compete with Google they failed. Microsoft are in the same markets that Google makes a huge amount of money from and yet they failed on most fronts.

You figure, basic economics says that if the cost of failure is low, you should expect lots of failures. It's not the "luxury of always succeeding."

>> There are unknowns that could completely disrupt Google's business models for example what if all search became voice based (siri-like) with better AI. Or what if a competitor develops much better AI capabilities into their search.

Google has fended off serious competition before, and if a start-up came out with a better search idea, Google would acquire them.

</comment></comment></comment><comment><USER4> Not exactly sure how this article defends its headline at all.

Considering that the author points to Motorola and Facebook Home as wins, his grasp of the tech scene seems rather weak.

<comment><USER5> I figure we should just flag the article off of the front page then?

</comment></comment><comment><USER6> I was lead to believe that Larry Page was Google's CEO. How does this get sent to print?

</comment><comment><USER7> "CEO Eric Schmidt" lol

</comment><comment><USER8> This article barely talks about its title topic.

</comment><comment><USER9> Google's greatest strength is that the tech press don't give a rat's ass about how they behave as a company as long as folks get free stuff.

</comment><comment><USER10> Technological experiments often call for risk-seeking and adventure, but when it comes to things that affect other people, a more conservative and level- headed approach is necessary.

For example, the utter recklessness involved in deploying calibration scores and shuttering 20% time is deplorable. That's an extreme lapse of professional responsibility.

(Sorry if this irritating, but as a matter of principle, I must keep doing this until Google does the right thing and one of the two founders issues a formal apology, and not only to me but to thousands of other affected people.)

<comment><USER11> Are you for real? I am trying to figure if you are a troll or whether you are truly psychologically damaged by your time at google?

Dude google is not going to change or issue an apology because a former employee rags on them on the internet... you do realize this right?

<comment><USER12> I think it's fascinating. If you read his other comments he's obviously brilliant. That said, he seems to be somewhat detached from reality over his episode at Google. Not that perf isn't shitty just that he seems to think he alone can do anything about it. It's like the endearing megalomania of a child who honestly believes he'll grow up to single handedly end world hunger or cure cancer. You just hope that after he realizes his limitations he isn't so distraught that it keeps him from accomplishing what he's clearly capable of.

<comment><USER13> Is the alternative implied here to acquiesce instead?

<comment><USER12> If you mean michaelochurch then no not at all.

"I must keep doing this until Google does the right thing and one of the two founders issues a formal apology, and not only to me but to thousands of other affected people."

I don't mind his Google bashing all that much. I just hope that he's accepted the futility of it. He can't really do any more damage to his reputation so he may as well keep going. This is a good place to broadcast to prospective/current Google employees. There could be people reading here who've already been slotted and don't even realize it. Whether Google accelerates your career or uses you as a disposable code monkey is determined entirely by their incentives. How would it benefit them to tell an under- performer that they're not going anywhere? Using the ambiguity of an eventual promotion as an implied carrot would generate better returns on their investment. It sounds like it'd work pretty well actually... Use Google's reputation to bring on a flurry of the most desirable new graduates and use them to do grunt work while they're motivated to prove themselves. Promote the top performers to "Real Googlers". Keep the middle around until they run out of steam or quit in frustration. Google gets cost effective grunt work and a larger share of the very best talent as a long-term strategic advantage against Apple/Microsoft/Facebook. If michaelochurch is as abnormally dauntless/foolhardy as he appears to be this could be a really big problem. Most people negatively affected probably go the "professional" route and quietly move on.</comment></comment></comment></comment></comment>


Learning Ruby and Rails, where would you start? - <AUTHOR> http://ontwik.com/ruby/learning-ruby-and-rails-where-would-you-start/

<comment><USER3> If you have done some web development before (maybe python, maybe php, maybe ASP 1.0) go read the getting started guides and get rolling. It's a big framework and there is a lot there but if this not your first rodeo it's not going to take long to get it. You know what MVC is and rails is just anther (good) web framework with some nice code generation to start you off fast. Oh and that ORM can be handy too!

If you are new to Ruby or web dev I would suggest you first start with Sinatra (<http://www.sinatrarb.com>

That will give you an idea of what basic basic web dev looks like in ruby without the overhead of a huge framework to take in.

After you have a simple hello world running with Sinatra then see about adding an external gem. (Maybe the 'shotgun' gem mentioned on the Sinatra site) then learn about bundler <http://gembundler.com> and get Sinatra running with that setup. Look at the template languages (erb, haml) and play with those. When you find yourself playing with middleware then maybe look at rails and see what it has to offer. At this point you will already have a felling for how everything fits together with a rack based web app (Sinatra and Rails both use Rack) at a little lower level and I think you will have a better experience with rails and be more productive because of it.

EDIT: Submissions that have links to articles with questions marks in the title are annoying. Thought it was an ask HN at first.

<comment><USER4> >Submissions that have links to articles with questions marks in the title are annoying. Thought it was an ask HN at first.

Agreed, so did I!

</comment></comment><comment><USER4> In all honesty, I would forget about Rails unless you have a really, _really_ compelling reason to pursue it. Rails is such a big framework, you could easily spend as much time learning it (Rails) as you would learning Ruby itself. I would recommend starting with Sinatra and Padrino for Ruby based web frameworks, you'll likely find you never need anything more unless you get a job at a Rails shop.

In terms of Ruby itself, having picked it up myself only fairly recently I would recommend the following:

\- unless you plan on maintaining someone elses code, jump straight into Ruby 1.9.

\- hang out in the IRC channels, #ruby-lang and #sinatra on Freenode. The community is awesome and really helpful.

\- the Sinatra video from Peepcode is really good

\- for books, I would recommend "Cloning Internet Applications with Ruby" (ISBN 978-1849511063), "Beginning Ruby from Novice to Professional, 2nd Ed" (ISBN 978-1430223634) and of course the current version of the Pickaxe book (google it :)

\- check out thechangelog.com regularly if you don't already

That's about it, good luck with it - I've found it fun so far and am currently developing my first web app on top of Sinatra which i hope to launch in a month or so!

<comment><USER5> Personally, if you want to learn something - jump in and learn it - do what interests you.

I started with Rails first (someone sent me a PDF of an early Rails manual - <USER2> started skimming it about 8am, finished the entire book of 300+ pages by supper - not sure I even ate anything in-between).

After playing with Rails for a few months I started to look at Ruby itself - it's an awesome language.

<comment><USER4> Absolutely - i guess I was more just saying think about the reasons first. When I started I was set on Rails too, purely because that's the thing most people talk about and for newbies it's easy to just see it as "the done thing" if you know what I mean, and not look for alternatives. I got onto Sinatra when I quickly realised Rails was way too heavy for what i wanted to do.

But you're absolutely right, the best way to learn anything is to just jump in, and absolutely nothing wrong with Rails!

<comment><USER6> I have had the same path that you describe. Started learning Rails and quickly realizing that Sinatra handles most of my needs, and is faster to get started with. It is also helpful to separate my ruby learning with understanding the rails framework. Will check out those resources!

</comment></comment></comment></comment><comment><USER7> A list of resources from the video:

Web resources:

\- <http://guides.rubyonrails.org>

\- <http://peepcode.com>

\- <http://railscasts.com>

\- <https://github.com/edgecase/ruby_koans>

Books:

\- [http://www.pragprog.com/titles/rails4/agile-web- development-...](http://www.pragprog.com/titles/rails4/agile-web-development- with-rails) : _Agile Web Development with Rails_

\- <http://pragprog.com/titles/ruby3/programming-ruby-1-9> : _Programming Ruby 1.9_ (Pickaxe book)

\- [http://www.amazon.com/Rails-Way-Addison-Wesley- Professional-...](http://www.amazon.com/Rails-Way-Addison-Wesley-Professional- Ruby/dp/0321601661) : _The Rails 3 Way_

<comment><USER8> Holy crap, thank you. Screencasts are great and all but I'll take text over video almost anytime when it comes to programming tutorials.

On a related note, I was recently directed to <http://asciicasts.com/> for railscasts in text format... quite nice.

</comment></comment><comment><USER9> Depending on how much or how little you know, this may be useful: Roadmap for Learning Rails[1].

In some sense, it's an ideal and you could probably learn some of these things at the same time. That said, if you know _nothing_ about HTML or SQL or <insert many other things here>, you're going to find Rails overwhelming and simply not get a lot of what you're doing. (Maybe that's fine too. Dive in, get lost, figure out parts of it. Lather, rinse, repeat. Some people probably learn this way, but some people no doubt like things a bit more orderly.)

[1] <http://techiferous.com/2010/07/roadmap-for-learning-rails/>

</comment><comment><USER10> Michael Hartl's Rails Tutorial is a good start <http://ruby.railstutorial.org/>

Also Railscasts is a fantastic resource.

<comment><USER11> Definitely check out the Rails Tutorial. There is a book (paper or bits), and really nice screencasts. The thing I like about Michael Hartl is he is really down to earth, fun, and acknowledges in the video if he doesn't know something. I bought the PDF and screencasts and am working through it right now--I'm on chapter 5.

Then, you and a friend should go build something!

</comment></comment><comment><USER12> I would recommend the following online tutorials. My wife, who'd done a little Java before, became a Ruby fan in an evening thanks to these:

<http://tryruby.org/>

<http://railsforzombies.org/>

<comment><USER13> I found Rails for Zombies big on theme but very small on substance. By the end, I asked myself... what did I actually _create_? Nothing! I typed in a few things into a Web browser that did some monkey-magic on the backend to tell me if what was in the textbox was "correct". They kept saying we were going to build "Twitter for Zombies", but I never did. What a let down.

</comment></comment><comment><USER14> I would emphatically recommend that if possible you attempt to give yourself a good grounding in ruby metaprogramming _before_ learning rails.

It will help you greatly in understanding how and why rails works the way it does.

The rails internals contain lots and lots of "magic" stuff, which if rails is your first introduction to ruby, you will find you have trouble differentiating what is ruby and what is rails's magic.

<comment><USER15> Are there any definitive resources to understand how Rails uses metaprogramming? I once failed in an attempt to understand the scope of metaprogramming in Ruby by searching for information in the pickaxe book (but gave up way too soon to be fair).

<comment><USER14> I'm not really sure, there's an O'reilly book "Metaprogramming Ruby" (<http://oreilly.com/catalog/9781934356470>) which i flicked through once. It seemed to mostly dicuss how ActiveRecord works. At the point I had access to a copy I was already pretty familiar with the concepts, so can't really say how good the book actually is.

I mostly picked things up by reading code and some blog posts whenever I came across an odd idiom.

</comment></comment></comment><comment><USER16> I tried to learn Ruby and Rails at the same time, but found it stressful to learn Ruby's elaborate syntactic sugar and Rails' enormous API at the same time. For me it certainly helped prototyping my application in Sinatra first and then dive into Rails once I understood more quirks of the language and it's web stack.

</comment><comment><USER5> Everything you need is here: <http://guides.rubyonrails.org/getting_started.html>

Those guides are an exercise in best practice framework documentation.

<comment><USER17> That's exactly where I started when trying to learn rails the first time and it was an utter failure that consumed an entire vacation and didn't really get me very far.

About a year after that I tried O'Reilly's HeadFirst rails book and got much much more out of my effort.

</comment></comment><comment><USER11> I would also add the Pragmatic Programmer's _Agile Web Development with Rails, 4e_.

<comment><USER18> Seconding this, I've been reading this off and on for the past week and found that it was perfect to get me started.

</comment></comment><comment><USER19> +1 on all the various comments recommending learning Ruby first and then Rails.

The Ruby standard library is pretty big, and the language has a large number of syntax options, which means that there are often 30 different ways to do something, and you'll often see over half of those in the real world. Those various options can be undeniably handy at times, but even after working in Ruby for several years it's not uncommon to come across code that uses something you haven't seen before.

Rails is great, but it's quite large and also quite clever, and clever can be very difficult to understand unless you have a solid grasp of the language.

Starting with something simpler like Sinatra would be a great idea, but I'd still recommend going through a Ruby book first.

The most difficult thing for me learning Ruby on Rails was separating what cleverness was coming from Ruby and what cleverness was coming from Rails, learning as much as you can about ruby first would be a huge help.

</comment><comment><USER20> I would recommend learning Ruby (if you don't know it already; if you come from other imp. languages, don't fall for the trap that 'it kind of looks the same' ; sure it does, but unless you learn a lot of the great syntax and language features, you won't be having too much fun imho) and then just starting a medium sized project for yourself to find out how rails works. Whatever you want to do, you can find it on Google; study the solution, try it out, tweak it to what you want to achieve. During such a project, you'll learn fast about practical Rails things. You might end up loving or hating it ;)

Edit: tutorials didn't help me much; they all blabla about the crud stuff which is boring as you'll probably never use it. That's why I suggest _not_ going that route.

</comment><comment><USER21> I actually went through this recently. Here's what took me from zero-to- functional-prototype in 6 weeks.

 _Note: I had a_ bit* of Python scripting experience, and knew my way around HTML and CSS.*

1\. A friend recommended SitePoint's Simply Rails 2. I went through that cover-to-cover, googling for where Rails 3 commands differ from Rails 2.

2\. I used an old tutorial for rolling my own user model from scratch (still in the Sitepoint piece): <http://www.aidanf.net/rails_user_authentication_tutorial>

3\. I ran "rails new" and started trying to code out what I was imagining. Anything that Simply Rails 2 didn't teach, I googled (e.g. FB/Twitter authentication with Omniauth, following/follower "friendship" models, Twilio integration, etc.).

If you're not coming into this with any scripting experience, I would absolutely recommend checking out <http://tryruby.org/> first.

</comment><comment><USER22> I just started learning RoR recently. As mentioned in the other comments, Michael Hartl's "Ruby on Rails Tutorial" (<http://ruby.railstutorial.org/ruby- on-rails-tutorial-book>) and the Rails Guides (<http://guides.rubyonrails.org/>) are all you need.

The Railscasts are a great resource as well - <http://railscasts.com/episodes/archive>

And a good starting resource for Ruby is the pickaxe book - [http://www.amazon.com/Programming-Ruby-1-9-Pragmatic- Program...](http://www.amazon.com/Programming-Ruby-1-9-Pragmatic- Programmers/dp/1934356085/ref=sr_1_2?ie=UTF8&qid=1301754318&sr=8-2)

</comment><comment><USER23> I am a "business guy" who was proficient in PHP. Here's what I did:

\- Bought a beginning Ruby book and gave it a quick perusal to get a handle on the fundamentals

\- Went through Michael Hartl's amazing Rails Tutorial (I skipped over some of the detailed sections on testing with the intention of returning at a later point.)

\- Finally, and most importantly, I converted an old PHP app into Rails. This helped me to see how what I wrote previously would fit into the Rails way of doing things.

</comment><comment><USER24> Mainly for complete beginners, but, learning Ruby and/or Rails is great and all, however, a lot of beginners tend to not understand the principles behind web development such as SQL or javascript or security or HTML.

What really astounds me is that people take ActiveRecord at face value and do stupid things such as Foo.all.sort_by(&:blah) or Foo.all.select {|x| x.stuff == "term"} and don't understand why it's such a bad idea.

</comment><comment><USER25> Well, with _why the Lucky Stiff's 'Poignant Guide to Ruby' of course ;-)

<http://en.wikipedia.org/wiki/Why_the_lucky_stiff>

One of the developers in the video suggested to learn some Ruby first before diving into Rails.

</comment><comment><USER26> After doing Rails for about 4 years, and Django for about 2 months (but I've been doing python for 10 years now) ... save yourself some pain and learn Django instead, if you can at all help it.

Ruby's documentation culture is hair-tearingly frustrating. Half a paragraph, 3 examples covering the barest functionality of your module, and pages of badly-interfaced mechanically-extracted documentation made me want to punch the monitor several times a day. Oh, but it's got a pretty web-2.0tard design- minded web site, and of course gitardhub, which is especially a joy if it goes down during a deploy.

Think I'm exaggerating?

<http://code.macournoyer.com/thin/doc/files/README.html>

</comment><comment><USER27> Starting from zero, I found Michael Hartl's Ruby on Rails 3 Tutorial to be excellent. YMMV.

</comment><comment><USER28> "Seven Dwarf Mine Station" ?

</comment><comment><USER29> here are the three that within in a month you should be able to write some sweet apps quickly.

1\. Head First Rails I first poohed this book but I had read 7-8 other books adn still was confused so I thought what the hell. I did each project several times and started making changes. Totally awesome especially the ajax integration parts. This is when I could actually make my own simple apps in less than a week.

2\. I loved Agile Programming book - totally awesome. Not enough apps though. Great explanations. Gentle exposure to Ruby.

3\. beginning novice to professional for ruby. I love this book. It is just plain fun. Good examples. I totally had fun with this. Peter is totally totally awesome - I wish he would write every tech book!!

Now you have the grounding, start making and asking questions.

What killed me was the UX/UI stuff. Then a friend suggested CSS Mastery book and using blueprint this got me clued in. Now I was not paralyzed. It was so awesome to see an app created in literally minutes.

I loved RoR - I miss it terribly. I disliked the community. Fanboyish. It was like being in all male high school with everyone thumping their chests and no help.

I still miss it very much. Whenever I code I first think in RoR then do it in php. My background was coldfusion, c#asp.net, java, etc. I need something dumb simple and php does the trick. And the people are nice and there are tons and tons of example to do anything. Also I needed something that is simple to deploy and maintain. Yeah yeah -RoR is easy to deploy - my first deployment took me several hours. Whereas php was minutes. In terms of sys admin and performance and optimization, I rather deal with php. As DBA, I do not really want an ORM. BTW when you feel good with RoR - check out Enterprise Rails - wow - good stuff on performance and optimization.

<comment><USER30> _Peter is totally totally awesome - I wish he would write every tech book!!_

Thanks. This is in the pipeline.

<comment><USER29> darn - I feel like a groupie - but it is true. I can't believe you are on HN!!!

</comment></comment></comment><comment><USER31> tar xzvf Django-1.3.tar.gz

<comment><USER32> You know, I used to develop web apps using both Django and Rails. What made me stop using Django was this sheer fanboism by Django community. I couldn't stand it. Sure, there was a time when Rails devs were known for their fanboism. But not anymore. I find the Rails community acts a lot matured nowadays. On the other hand the Django community is going downhill. For every web framework recommendation question on StackOverflow, its "Django! Django!". They don't even bother to see the requirements. It gets even uglier on Reddit. A Django fanboy even bothered to start this site: <http://ihaterubyonrails.com>

<comment><USER33> Could you please backup with your claims with some evidence?

<comment><USER33> May i know what did i post that is irrelevant to this discussion to get downvoted? You down voted me because i asked for evidence? As a mater of fact django devs were receptive to Criticism <http://news.ycombinator.com/item?id=1777403>

<comment><USER19> Because responding to someone's statement of opinion with "prove it" isn't an effective way to further a conversation.</comment></comment></comment></comment></comment>


Amazon given go ahead to launch thousands of satellites - <AUTHOR> https://www.euronews.com/2020/07/31/amazon-given-go-ahead-to-launch-thousands-of-satellites-to-boost-internet-access-worldwide <comment><USER2> I was wondering about this - shouldn't approvals regarding things to be put in space, which is similar to doing thing in international ocean waters, need some international agency approval and not from just a USA govt agency?

<comment><USER3> Unless you violate a convention or a treaty (or the laws of the flag you are sailing under) you can do w/e you want in international waters, same goes for space.

</comment></comment><comment><USER4> I wonder how Amazon will be able to pull profitability with this, compared to Space-X? For Space-X to make it work, they are launching on their own re- usable rockets, and I believe that they are banking on the projected Starship cost models to really deliver the bulk of their satellites at a cheaper cost.

Amazon may be counting on Blue Origin, but I'm wondering what the chance of that working properly and within budget right out the gate are? And as far as I know, New Glen is projected to be in the same ballpark as Falcon Heavy, but nowhere near the delivery capacity of Starship.

</comment><comment><USER5> This sounds like bad news for anyone into astrophotography. The recent proliferation of satellites are already a big problem [0].

[0] [https://astronomy.com/news/2020/03/nasa-needs-you-to- photogr...](https://astronomy.com/news/2020/03/nasa-needs-you-to-photograph- starlink-satellites-with-your-smartphone)

<comment><USER6> Wall-e is starting to look quite prescient:

[https://www.youtube.com/watch?v=RmG5tUCrrsA](https://www.youtube.com/watch?v=RmG5tUCrrsA)</comment></comment>


Ask HN: (JS) Wouldn't it be simpler if `await` were a method on `Promise`? - <AUTHOR> Instead of requiring special new syntax like we have now:
const result = await doAsync();
We could have a method on the returned Promise object called 'await':
const result = doAsync().await(); <comment><USER2> 1) There could be an `await` method already defined on the Promise. It's just an object.

2) `await` can work with anything that conforms to the Promise spec, native promises or Bluebird or what have you.

3) Sometimes, a method doesn't return a Promise, but a value. In those cases, the await syntax returns the value. Can't do that with a method.</comment>


Hiring and retaining high quality programmers - <AUTHOR> http://darwinianweb.com/archive/2006/338.html <comment><USER2> Great article - I am one of those guys who dropped from college because I simply couldn't see myself sitting in class learning about Nostradamus and interpretive theater while I was thinking of the application I was building at home.

I have since started college again (online courses) but dropping out for that time was the best decision I ever made. Unfortunately, to many employers require that piece of paper that says, "I know my stuff."

<comment><AUTHOR> _'... I am one of those guys who dropped from college because I simply couldn't see myself sitting in class learning about Nostradamus and interpretive theater while I was thinking of the application I was building at home ...'_

Being smart, determined and doing stuff is good. But learning in a formal (or informal setting) has a couple of objectives. The first and most important one is to teach you _how to learn_. The second some fundamental skills. The third though cannot be taught, how to think.

To me original thinking backed up by skill and determination matters just as much. But theres one other dimension that education measures. The ability to complete.

 _'... Unfortunately, to many employers require that piece of paper that says, "I know my stuff." ...'_

And it also does not demonstrate you can think. In fact it's really the bare minimum requirement.

</comment></comment><comment><USER3> Great points. I agree with what the author says. In short they must be given freedom/independence</comment>


Image Recognition Trends in 2020 - <AUTHOR> https://imagga.com/blog/image-recognition-trends-in-2020/ <comment><USER2> On a slight tangent, when I saw "in 2020", my initial reaction was to think this was a post speculating about the image recognition trends in the far future.

And then I realized it is November 2019.

<comment><USER3> 2020 is the successor of "the new millennium", and is now succeeded by 2035 and 2050. For some reason we affix all kinds of goals across society to a handful of years. It's really strange and makes those years sound like the far future even when they are already in the past.

</comment></comment><comment><USER4> The final "global image recognition market" chat must be one of the worst visualisations ever... What is the sense of it starting and ending with 0 for both lines ? Why not plot round in a circle?

<comment><USER3> That chart is indeed all around "not great". It has no business being a line chart since the lines are meaningless (what's 50% between Barcode Recognition and Facial Recognition?), the two points at zero make no sense, and one of the axis is completely unlabeled (presumable compounded annual growth rate?)</comment></comment>


Ask HN: RoR/Ruby mainstream yet or still underground? - <AUTHOR>

Do you guys think, its practical to rely on Roby/RoR technology to expect a well-paying job in current market? Having worked in several technology and platform, I have totally fallen in love with RoR/Ruby world - but at the end of the day, I need to make a living too! Currently out of job, and spending some quality hacking time with an RoR app, am wondering what you guys think in terms of RoR going mainstream for jobs in the real' world! <comment><USER2> mainstream. Where you based?</comment>


Introducing Microsoft Silverlight - <AUTHOR> http://blogs.msdn.com/tims/archive/2007/04/15/introducing-microsoft-silverlight.aspx <comment><AUTHOR> _'... Tim Sneath: Musings of a Windows Vista Technical Evangelist ...'_

worth adding just for the blog byline</comment>


CompTIA - A malicious site? - <AUTHOR> http://flickr.com/photos/mattezell/sets/72157606012121192/ I recently got my A+ certification so that I can nab a job to hold me over until I can get a programming gig (no one wants to hire a CS major for tech work).  I headed to CompTIA's website to download my certificate and was presented with a Firefox's "Reported Attack Site" warning.  According to Google's Safe Browsing Diagnostic report, there are 2 pages being hosted at CompTIA that result in the installation of Malicious content without users consent...  Maybe the CompTIA organization needs to brush up on their security information...<p>http://blog.eznet.frih.net/?p=88 <comment><AUTHOR> I recently got my A+ certification so that I can nab a job to hold me over until I can get a programming gig (no one wants to hire a CS major for tech work and no one wants a programmer with 'no' experience). I headed to CompTIA's website to download my certificate and was presented with a Firefox's "Reported Attack Site" warning. According to Google's Safe Browsing Diagnostic report, there are 2 pages being hosted at CompTIA that result in the installation of Malicious content without users consent... Maybe the CompTIA organization needs to brush up on their security information...

<http://blog.eznet.frih.net/?p=88>

<comment><USER2> This isn't really related to CompTIA, but in regards to nobody wanting to hire a programmer with "no" experience.

If you're having a hard time getting an entry-level gig somewhere, I would suggest building a code portfolio. It should contain code samples (in multiple languages, if you can) as well as some working program code.

Web development is going to be the easiest place to get your foot in the door, so maybe you should build a web page with some forms, some javascript, etc etc etc.

There are entry level jobs out there, you just have to put yourself ahead of everyone else trying for them.

<comment><AUTHOR> Thanks for the pointers... Yea, I have recently acquired a rough understanding of Python and am picking up Django at the moment to hopefully increase my marketability and show my ability to pick new skills...

<comment><USER2> As someone who does hiring of entry level people from time to time; making the effort and being enthusiastic has been the deal-sealer more than a few times.

Employers like to know if you're interested in the work or the paycheck. (At least your primary interest - everyone wants to get paid lots and lots of money, but for the real geeks like us; reading YC on a Sunday, we're in it because we love to hack.)

</comment></comment></comment></comment><comment><AUTHOR> Called CompTIA today - at first they said I was mistaken... Then I sent links to my flickr account and to the various tech/certification sites making the "maybe they should increase their Security+" crack. I was called back this afternoon and told that their tech dept is working with Google (?) to resolve the issues...</comment>


Did WikiLeaks Sell Out Snowden To The Russians?  - <AUTHOR> http://www.businessinsider.in/Did-WikiLeaks-Sell-Out-Snowden-To-The-Russians/articleshow/22269057.cms <comment><USER2> Russian control of Wikileaks makes sense of Snowden's actions. Then again, it may just be conincidence?</comment>


Consumer Reports Now Recommends MacBook Pros - - <AUTHOR> http://www.consumerreports.org/apple/consumer-reports-now-recommends-macbook-pros/ <comment><USER2> > "The new average battery-life results are, in order, 15.75 hours, 18.75 > hours, and 17.25 hours."

This is even more of a red flag than the original tests. On what planet do you get 18 hours of battery on a single charge? Or even half of that?

Something is way off here.

<comment><USER3> This is only browsing web pages in one tab though right? Not even running multiple apps. Nobody does that anyway. I for instance have 50+ tabs open on any given day.

<comment><USER4> Normal people don't have 50+ tabs open, ever. Your idea of who represents "nobody" is upside down.

<comment><USER5> I think you have an idealistic view of the way normal people use computers, making an absolute statement like "ever".

Here's an example of a "normal" person with 1250 of them: [https://www.reddit.com/r/talesfromtechsupport/comments/4urdh...](https://www.reddit.com/r/talesfromtechsupport/comments/4urdhi/how_many_tabs_is_too_many/)

It's not a unique occurrence: [https://www.reddit.com/r/talesfromtechsupport/comments/5iixe...](https://www.reddit.com/r/talesfromtechsupport/comments/5iixeu/213_tabs/)

<comment><USER4> Don't you think the fact that it was submitted to /r/talesfromtechsupport implies that it was something of note, and that a handful of people offering of anecdotes of their own bizarre encounter with a tab hoarder support my claim that it's not the way most people use a browser?

<comment><USER5> My point is that you didn't say "it's not the way most people use a browser", you said that normal people don't "ever" use that many tabs. You made an overly absolute statement and I'm refuting it.

<comment><USER4> I concede that. But your initial use of "nobody" is also overly absolute.

<comment><USER5> That was someone else, not me.

</comment></comment></comment></comment></comment></comment></comment></comment><comment><USER6> So we all moved to Linux for nothing? ;-)

<comment><USER7> Not so sure people that take Consumer Reports seriously run Linux.

<comment><USER8> I honestly don't see any logical negative connection between those two groups of people. Actually, I see many potential good reasons why someone running Linux would care to listen to them. Care to explain your thinking?

<comment><USER7> Out of the box, most Linux boxes are broke, especially with new hardware when compared to the status quo Macbook Pro. You have to wrestle with kernels, hardware, software updates, different pkg repos, GPU power management, GPU drivers, touchpad, HiDPI, Thunderbolt, etc. (HN: please spare me the drama of quoting this list and nitpicking, you know a subset of it is true.)

My Dell precision 5510 (optionally ships from Dell with Ubuntu) takes an hour or two of work from a competent Linux nerd to be on par with a Macbook. In the past I owned a System76 Galago Ultra Pro which prides itself on being Linux ready. Instead it shipped with impressively miserable battery life, "meh" keyboard, and no UEFI (what year is it@!?).

If Consumer Reports were to review either of those laptops, they would give it a failing grade relative to a Macbook Pro.

Yet Linux still thrives fueled by the DIY or open source communities. These communities look for different thing out of the box. Furthermore, the person who consider Linux would have probably discovered the Safari bug LONG before it took Apple + Consumer Reports to find the real cause. This person would probably run Chrome or Firefox until the inevitable fix rolled out from Apple.

<comment><USER9> So, the reason for the inconsistent battery life was a Sufari bug (I just scanned the article, didn't read the whole thing)?

<comment><USER7> Pretty much[0]:

> After working with Apple over the holidays, Consumer Reports now says that > the problem was caused by an "obscure" Safari bug specific to page caching, > which the publication disables when it runs its battery tests. To test > battery life, Consumer Reports sets laptop screens to a specific brightness > level and then loads a series of webpages in the laptop's default browser > (Safari in this case) in a loop until the battery dies. Apple suggests that > disabling browser caching for a test like this doesn't reflect real-world > use, but it does make sense for a synthetic test—users will continually read > new pages rather than visiting the same static pages over and over again, so > Consumer Reports wants to make sure that its test is actually downloading > data over the network rather than simply reading cached data from the disk.

[0] [http://arstechnica.com/apple/2017/01/consumer-reports- will-r...](http://arstechnica.com/apple/2017/01/consumer-reports-will-re-test- macbook-pro-batteries-after-apple-fixes-bugs/)

<comment><USER9> What about users that reported bad battery life?

<comment><USER6> Migrating to a new Mac puts some stress on battery while everything is indexed for Spotlight or backed up to a Time Capsule. That's why Macs will tend to have bad battery life in their first few days.

<comment><USER9> Meh.

Doesn't everyone just restores from a previous backup? Why would one start from scratch?

Most importsntly, I doubt a developer wouldn't see there's a process draining the battery.

</comment></comment></comment></comment></comment></comment></comment></comment></comment><comment><USER10> I'm quite surprised with the battery life numbers they are reporting:

\- Macbook Pro Escape: 18.75 hours \- Macbook Pro 13": 15.25 hours \- Macbook Pro 15": 17.25 hours

I've tested both the Macbook Pro Escape and the Macbook Pro 15" and under _very_ light work load (web, email...) I'd say they were closer to 9 and 8 hours, which, by the way, I find pretty decent considering weight and dimmensions.

I really don't know what methodolgy CR uses, but seems to me that is not very realistic.

<comment><USER11> According to this page, Consumer Reports tested this computer at 100 nits brightness, which is 20% of the maximum brightness. This is probably a lower brightness level than the average user, contributing to the battery lasting longer than expected.

[http://www.consumerreports.org/laptops/macbook-pros-fail- to-...](http://www.consumerreports.org/laptops/macbook-pros-fail-to-earn- consumer-reports-recommendation/)

</comment></comment><comment><USER12> The thing is, I would actually tolerate a larger body/battery if it would realistically get me 9 hours. I know that it's not sexy, and Apple needs to retain its image.

I would think that laptops with insane battery lives would be desirable, particularly in the business/enterprise/travel markets. Maybe not.

</comment><comment><USER13> They invented this super cool tech to increase battery life, called larger batteries. For some reason every time the processor gets more efficient, the battery gets smaller. Soon we'll be able to use phones as chinese throwing stars.

</comment><comment><USER14> Still unrepairable and unupgradable (unlike previous MBP non-Retina), foisting ultimate, overpriced Apple control over a previously much more flexible product. Also, the touchbar and new keyboard aren't very practical.

When there is a Retina model with RAM DIMMs, changable SSDs and superior keyboard, I'd consider looking at MBPs again.

<comment><USER15> Battery too. The hilarious thing is that they could do all of that and probably only add a few mm thickness. Check out the Dell XPS or Thinkpad X1 Carbon lines.

Also hilarious to me is how thick the dongles are, and how the power brick is the same (other than now needing an expensive proprietary Apple USB-C USB 2.0 higher-than-spec power delivery cable which is sold separately from the actual brick and an extension cable which is also now sold separately).</comment></comment>


Ask HN: Where has Cosmos DB fallen short? Is it gaining traction? - <AUTHOR> CosmosDB has a few really interesting features. It has 5 different consistency models, ranging from strong to eventual. It has an SQL, Graph, Mongo, KV, and Cassandra interface out of the box. It has scalable throughput, scalable storage, HA, cloud function triggers, cloud function stored procedures (within which are atomic transactions), and automatic indexing of any field.<p>Has anybody here committed to it? What have your experiences been? From what little fiddling I've done, it has been reasonably straightforward to use. <comment><USER2> I haven't used it. Wikipedia explains that it doesn't have (equivalents to) ORDER BY, EXPLAIN, transactions, Skip/Take.

It looks like it's proprietary -- but worse, you can't even run it locally. So you're locked in to a closed source DB service provided by one vendor that is entirely irreproducible outside of that vendor's environment.

That sounds like somewhere it's fallen short to me. What are you supposed to do if you have to leave Azure for some reason? Apparently you can't even access backups without raising a support ticket.</comment>


Lively Linear Lisp – 'Look Ma, No Garbage' (1992) - <AUTHOR> http://home.pipeline.com/~hbaker1/LinearLisp.html <comment><USER2> _" Some have suggested that garbage collection not be done at all [White80] or after the program has finished [Moon84] (comment on the Boyer benchmark). Linear Lisp provides a hyper-clean environment in which garbage is never produced, and therefore garbage collection is not necessary."_

 _" However, linear logic's lack of sharing may introduce significant inefficiencies of its own."_

 _" The sharing of data structures can be efficient, because sharing can substitute for copying, but it creates ambiguity as to who is responsible for their management."_

These quotes foreshadow the goals of Rust 20 years later, whose eventual intent was to realize both the doesn't-require-a-garbage-collector property of linear logic with the efficiently-sharing-data-is-still-possible property of traditional systems languages by separating these concepts into ownership (covering the former) and borrowing (covering the latter, and built on top of ownership).

<comment><USER3> > These quotes foreshadow the goals of Rust 20 years later, whose eventual > intent was to realize both the doesn't-require-a-garbage-collector property > of linear logic with the efficiently-sharing-data-is-still-possible property > of traditional systems languages by separating these concepts into ownership > (covering the former) and borrowing (covering the latter, and built on top > of ownership).

The idea of borrowing is not original to Rust in any way, and is found from the first application of linear logic to PL type systems in Wadler's "Linear types can change the world!" onward, including Vault, Cyclone, etc. Any system without it would be impractical for writing real programs.

<comment><USER4> It appears that just like there are those that think C was the genesis of systems programming, with very little attention being given to what happened 15 years earlier and beyond Bell Labs walls, in 20 years from now same might apply to Rust and the languages that were its inspiration.

<comment><USER5> > It appears that just like there are those that think C was the genesis of > systems programming, with very little attention being given to what happened > 15 years earlier

This is why I think it's important to get familiar and listen to Old Masters like Rob Pike, Brian Kernighan, John Ousterhout, and even war stories of Richard Stallman, and chase down their references and get familiar with them, too. It's not that there's nothing left to do, but an awful lot _has_ been done. We can at least learn from it...

> and beyond Bell Labs walls

As I cite Pike, Kernighan, ... :)

<comment><USER4> There is a Rob Pike talk where he praises the compile times of the Algol compiler he was using as a student for example.

</comment></comment></comment></comment></comment><comment><USER6> The 'use-once variable' described in the OP is the intellectual ancestor of Rust's borrow checker. It got a lot of attention from programming-languages researchers (such as the author of the OP) after it got a lot of attention from academic logicians after the publication in 1987 by logician Jean-Yves Girard of a seminal paper entitled 'Linear Logic', the full text of which is available at [https://www.sciencedirect.com/science/article/pii/0304397587...](https://www.sciencedirect.com/science/article/pii/0304397587900454)

That paper is the most abstract, airy, 'ungrounded' paper I have ever read that will probably have a significant positive practical impact on human flourishing (via Rust's borrow checker).

<comment><USER7> More specifically, while linear logic grants the 'must use-once variable', Rust implements "affine types", where values must be used no more than once.

<comment><USER3> Strictly speaking, Rust doesn't even have affine types, since even move-once variables can be borrowed multiple times before they are moved. You could argue that Rust could be elaborated into a system with affine types, but the elaboration isn't particularly simple in all cases.

<comment><USER6> I prefer to think of a reference to a type as a type in its own right _separate_ from the borrowed type. Looked at that way, Rust does have affine types.

To bring the discussion back to my first comment, it would've been less likely for anyone to have invented the borrow checker if programming-languages researchers weren't paying a lot of attention to use-once variables, and languages researchers would've been less likely to be paying attention were it not for Girard.

I haven't read Girard's paper in 20 years, but I would be extremely surprised if it contained any mention of borrowing or references, so Girard must share any credit for Rust's borrow checker with later innovators, and here I would be remiss not to mention Graydon Hoare.

<comment><USER3> > I prefer to think of a reference to a type as a type in its own right > separate from the borrowed type. Looked at that way, Rust does have affine > types.

The reference type is a separate type, but the & borrowing operator is a use of the original path. You can borrow (i.e. use) the same path multiple times before it is moved or implicitly destroyed.

<comment><USER6> Good point: my assertion in grandparent that "Rust does have affine types" is wrong.

Do you agree with my belief that it is significantly less likely the borrow checker would've been invented if programming-languages researchers hadn't paid a lot of attention to linear and affine types? Even though a Rust coder can take as many non-mutable references to a location in memory as he wants, there are certain operations (e.g., move) that the coder can only do once to it, and the inventor(s) (probably Graydon Hoare) of the borrow checker must have explored that part of the design space extensively, and it seems to me it would have been very non-obvious that it was worth exploring extensively to someone not influenced directly or indirectly by Girard.

<comment><USER3> > Do you agree with my belief that it is significantly less likely the borrow > checker would've been invented if programming-languages researchers hadn't > paid a lot of attention to linear and affine types?

As I mentioned in another comment, the concept of borrowing was already present in the earliest applications of linear types to programming languages. There was contemporaneous research into region systems for ML. Later languages like Vault and Cyclone combined these two ideas, using substructural types to manage regions.

From a language feature perspective, the biggest innovation of Rust was integrating the ideas from Cyclone and other research languages with the emerging C++11 style of programming with implicit destructors, move semantics, and smart pointers.

</comment></comment></comment></comment></comment></comment></comment><comment><USER8> Linear Logic, Linear Lisp, Linear Types and Concatenative Languages: [https://cdiggins.github.io/blog/linear-logic-and-linear- lisp...](https://cdiggins.github.io/blog/linear-logic-and-linear-lisp.html)

<comment><USER9> Oh awesome.

See also Conal Elliott's "Compiling to categories" ( [http://conal.net/papers/compiling-to- categories/](http://conal.net/papers/compiling-to-categories/) ) where he is converting Haskell automatically to point-free form (like a concatinative language but not quite) and then instantiating that over different Categories to get different correct programs from the same expression.

I've been working with Joy recently and I think this stuff is "the next big thing" for PLs. [http://joypy.osdn.io/notebooks/Types.html](http://joypy.osdn.io/notebooks/Types.html)

<comment><USER10> Cool project! I've been working on typing for stack-based languages. Although I got stuck trying to make the inferencer work on higher-order functions. Kleffner's Master thesis supposedly explains how to accomplish that, but I haven't been able to wrap my head around it yet. I'd be interested to hear how you have solved the problem in Thun.

<comment><USER9> My original implementation is in Python and I documented a bit of research and implementation of type inference here: "The Blissful Elegance of Typing Joy" [http://joypy.osdn.io/notebooks/Types.html](http://joypy.osdn.io/notebooks/Types.html) The "Type Inference in Stack-Based Programming Languages" talk given by Rob Kleffner informed it. I don't recall now whether I read his thesis but it's likely. I probably couldn't wrap my head around it either.

For typing combinators (Joy's higher-order functions) I tried making a hybrid inferencer and interpreter that just evaluated them and it worked. (Incidentally that's what drove home to me the categorical nature of Joy. When I read Conal Elliott's "Compiling to Categories" I recognized what I had done.) In Joy the higher order combinators "don't care" if they are working on e.g. values or types. In other words they only care about the shape or structure (structural typing) of the data on the stack.

When I wrote the interpreter in Prolog and then wrote the inferencer in Prolog I noticed they were the same code, so I deleted one of them. In Prolog, you can pass a stack and compute values or pass logic variables and it will tell you what kind of stack a given expression expects/generates. If you implement math ops with CLP(FD) you get a nice constraint compiler that get generate new Prolog implementations of Joy expressions. Sick, eh?

In _both_ Prolog and Python I haven't yet closed the loop for recursive combinators. Meaning the type inferencer generates the base-case and then the case for recurring once, then twice, and so on. I know the answer is some simple application of fixed-point theory or something, but I'm an idiot, and I've been working on other aspects (because I'm sure the solution is like decades old in the "compiling FP languages" literature. "Somebody else has had this problem.")

In any event, I don't think I'll have to figure it out, because I just found out that the next steps I was going to take have already been done by the "Seven Sketches" folks and then some: [https://news.ycombinator.com/item?id=20376325](https://news.ycombinator.com/item?id=20376325)

I'm pretty sure most of that stuff would make great Joy combinators. And _something_ in there would be the way to deal with e.g. _genrec_ and _x_ combinators.

</comment></comment></comment></comment><comment><USER11> Garbage is always produced somewhere. It might be in variables which are no longer used before being freed, or in wasted space inside the allocator itself. What actually matters is (a) whether this performed better than GC'd Lisp equivalents of the era, and/or (b) if a GC Lisp is easier/faster/cheaper to write code for.

<comment><USER2> Agreed that it's important not to overlook that allocator implementations often curiously resemble garbage collectors, although even keeping this in mind the act of eliminating what is usually referred to as "garbage collection" still turns out to be valuable since that garbage collector lives on top of the allocator already; having only one garbage collector in one's program can be advantageous to having two garbage collectors, one atop the other.

<comment><USER11> The OCaml GC uses huge long-lived blocks from the underlying allocator (malloc) so I don't think having two allocators is really a problem. Even less so on a LISP running on a LISP system where the LISP is the system allocator.

</comment></comment></comment><comment><USER12> Any authors of the Carp programming language reading this?

<comment><USER13> (Carp is a statically-typed GC-free lisp for real-time applications.)

The "Carp 0.3.0 release" is being discussed today as [https://news.ycombinator.com/item?id=20368969](https://news.ycombinator.com/item?id=20368969) .

</comment></comment><comment><USER14> Thread from a couple years ago: [https://news.ycombinator.com/item?id=14248419](https://news.ycombinator.com/item?id=14248419)

</comment><comment><USER15> Why is linear logic called linear? What is the connection to the usual idea of linearity?

<comment><USER16> The semantics resembles structures from linear algebra. Linear logic was initially seen as a linear algebra built on coherent spaces. A coherent space is a reflexive undirected graph.

Alternatively: The category of finite dimensional vector spaces over finite fields is a model of linear logic. [http://www.cs.bham.ac.uk/~drg/bll/steve.pdf](http://www.cs.bham.ac.uk/~drg/bll/steve.pdf)</comment></comment>