Better HN
topnewbestaskshowjobs
Log inSign up

papsosouid

2,420 karma · joined Apr 9, 2012 (14y ago) · 1,199 submissions

Submissions

comment 13y ago · link · parent

>Please, please, don't poison your career on focusing on a single language

My career is likely older than you, I think it'll survive the horrors of using a good language. I've been running production web sites on haskell for a year so far, and it has been great.

comment 13y ago · link · parent

>The "designer friendly" templates push all of the lift:foo stuff into class names in the template.

Oh, I realize you can do that also, I just didn't recognize that there's any difference. <lift:foo> and <div class="lift:foo"> are identical right? Heist lets you do both too.

>That is funny to hear that haskell compiles faster.

Not in the general case, but specifically with snap. I'm not sure what magic they have going on in their dynamic loader, but it is much faster than the one yesod uses for example (another haskell framework).

comment 13y ago · link · parent

>One advantage of node that wasn't mentioned is the ability to share server side and client side code

You can do that with lots of languages, using one of the langX->javascript compilers.

>Avoiding discrepancies in the same form validation written in two different languages

What form validation are you doing in javascript? I can't actually think of any client side validation that isn't just a regex.

comment 13y ago · link · parent

"Extremely unpleasant"

comment 13y ago · link · parent

I would definitely start with learn you a haskell. It makes a much better introduction to the language than RWH. RWH is great when you have learned the basics and want to start tackling bigger problems.

Xmonad is a pretty common recommendation for looking at "good haskell code", in particular the overall design and how they keep the IO part minimized and isolated so the bulk of the application is easier to unit test. I think the standard libraries the come with GHC are good examples too.

comment 13y ago · link · parent

You are contradicting yourself about parametric polymorphism. First you acknowledge it doesn't exist, then you claim a limited workaround solves it.

>It's definitely not harder to prototype in - and I say this as a functional programmer

Have you used haskell to make the comparison?

>if you're writing Go idiomatically, you really shouldn't be thinking very much about the types as you write them.

I don't understand where you are coming from here. I am not thinking about types, that is why I need the compiler to point out when I mess them up. The problem is go has such a limited type system, that you have to change much more code when you refactor, and the type system is inadequate for catching many errors, in particular dealing with error handling. The combination makes go worse for refactoring than haskell. It is certainly much better than python for example, but you seem to be convinced that go is the top of the spectrum and nothing can exist above it.

comment 13y ago · link · parent

Yes. I think you are seriously underestimating the intellectual capacity of those people. Telling them "it doesn't matter how nice it is, or clean it is, or generic, or reusable, or maintainable, it is just to see if you can do basic introductory level code" solves the problem. Anyone who still stands there like a moron writing nothing is useless as a developer, regardless of the reason they stand there.

comment 13y ago · link · parent

>Go is going to look hideous to you because you're probably expecting functional things like list comprehensions

Nah, list comprehensions are just syntactic sugar and not used much in haskell. Python seems to encourage their use a lot, but you hardly even see them in haskell code.

>a very intricate type system allowing for things like generics (which Go doesn't have either).

That is definitely one of the big problems, but I take issue with the characterization of that as needing "a very intricate type system". Parametric polymorphism is very simple, and has been a completely solved issue for a very long time. There is simply no excuse for a brand new language to be decades behind on something so easy to do right.

>being incredibly easy to prototype in, and being incredibly easy to refactor painlessly.

Those are actually two of the other big issues going from go to haskell. Go is harder to prototype in, and it is easy to add bugs when refactoring because the type system is so poor.

comment 13y ago · link · parent

>I think FizzBuzz does filter obsessive people.

FizzBuzz doesn't filter anyone, the people using it do. It is not difficult to explain the purpose of the exercise, and that easily resolves the problem for people looking for "clean" solutions.

comment 13y ago · link · parent

Can I ask what language you are used to? I hear how nice go is as a language a lot, but coming from haskell, go is hideous in comparison.

comment 13y ago · link · parent

If they actually, honestly didn't want their inane spam posted on HN, they could easily achieve that simply by returning a non-response or redirect or error for any requests with a HN referer header. They do not do that because they actually do want to continue getting traffic from the inexplicable portion of HN that insists on posting their crap all the time.

comment 13y ago · link · parent

>I remember the first time I interviewed for a front-end programming position and got asked how to do something in JavaScript on a white board

>how little it had to do with the actual job.

That doesn't make any sense. How is solving a problem with javascript irrelevant to the job of a front end developer? That's what they do.

comment 13y ago · link · parent

The entire point is "is this person capable of the most basic fundamentals of programming (conditionals, looping). That's it. We don't filter out obsessive people with it, they demonstrate that they understand conditionals and looping, what's the problem?

comment 13y ago · link · parent

Why should programming contest problems be tests of practical sysadmin skills? That makes no sense at all.

comment 13y ago · link · parent

>What non-technical hobby or interest do you have?

That seems like a poor choice. Are you trying to eliminate people who don't have non-technical hobbies for some reason?

comment 13y ago · link · parent

He says on twitter. To gain more publicity from HN. Just because he hates that there's some people here who call him on his bullshit, or even if he hated HN for real, that wouldn't mean he doesn't use it for marketing.

comment 13y ago · link · parent

>Trivial puzzlers like:write a fizzbuzz program

That isn't a "puzzler", in any way, shape or form. It is quite literally "write the most basic, simple, trivial program possible". There is no trick to it, no gotcha, no special information that makes it suddenly go from hard to easy. It is always easy, and is a practical test of actual programming knowledge.

comment 13y ago · link · parent

>That is likely just my misreading of the wiki page.

I would say the fault there lies 100% on the docs, not you. The docs are heavily focused on using the attributes that are provided out of the box, rather than on how to write your own.

>But then it jumped straight into the bind and apply tags

That's the equivalent of lift:surround. There's nothing special about those tags, they are just part of the set of default splices that you can use.

>With the latest lift templates, there are no custom tags. Nor are there custom attributes.

What are there instead? The docs still appear to be talking about lift:stuff tags and attributes. There aren't really custom tags or attributes in heist either, unless you want there to be. You are really just binding some haskell code to a tag or attribute. That tag could be a real html tag (like the splice included by default that is bound to the html tag, which consolidates multiple head tags into one). Or it could be a any tag you make up, like we bind a splice to the <user> tag which replaces the contents with the user data.

>Also, I'm highly curious on the upsides of the Haskell framework you are using.

Shockingly enough considering how haskell is known for slow compile times, faster compilation is one of the upsides. Mainly we used snap because it gives us the same thing we liked about lift (templates), but with no assumptions about how things have to work, a more helpful community, and a better language.

comment 13y ago · link · parent

>I have 8 GB of Ram and SSD

Me too.

>but it's less of an issue with Play than in Rails or Django or whatever

>It's worth noting what Play gives you when compared to Rails, Django and the like.

Perhaps for some, but we have no interest in dynamic languages or frameworks written in them. We were evaluating frameworks for decent languages only. I was only commenting on the compilation speed issue because they constantly brag about fast iteration when it is no faster than a typical bloated J2EE monster.

comment 13y ago · link · parent

We ended up using Haskell, which is also famously slow at compiling. But it has been significantly faster than play thus far (using snap's development mode).

comment 13y ago · link · parent

>They got stronger with time

Stronger how? It is just a pseudo-html document tree being manipulated in scala. I'm not sure how it can become stronger or weaker.

>For the TAL stuff, it looks like logic is directly placed in an attribute.

It is placed wherever you want it. Using a TAL loop attribute is no different than doing the same thing in lift. The only difference is that lift doesn't show doing that in the docs, so people tend not to do it.

>Again, the difference comes in how the templates are "split" and placed in the app

I still don't understand what you mean. We literally took our lift templates and used them in heist just doing a search and replace s/lift://g. We just had to change the scala code "snippets" to be haskell code "splices".

>I'm still interested to hear an analysis if you are up for giving it

Lift assumes too much, and if you go outside those assumptions you are basically stranded. Combined with just being an immature framework where there's things missing/incomplete, and an outright hostile community, it makes things pretty difficult. Form handling was the biggest sticking point, especially when you want to have forms that aren't protected by their CSRF tokens and need to work with cookies disabled. It becomes a case of "well, we don't want to support that so just do it yourself from scratch".

Play we had tons of issues with the weird scala templates they use. It would barf frequently on what appeared to be perfectly valid syntax. Combined with the "developing with play is super fast!" sales pitch, while being slower to recompile than lift was, we didn't bother spending much more time on it.

comment 13y ago · link · parent

I don't know what you are referring to. What strengths? They are html templates.

If you are going to restrict "peers" to jvm frameworks then I really can't offer you anything. I haven't used any other jvm frameworks, I tried the two scala options (lift and play) and ran screaming.

comment 13y ago · link · parent

We did. The difference is negligable, it takes a fraction of a second to hit f5. In fact, it costs time fairly often as you save the file, notice right away that you have a typo, fix it and save again, but now it is still busy compiling from the first time so you have to wait out two compiles.

comment 13y ago · link · parent

http://en.wikipedia.org/wiki/Template_Attribute_Language is the most widespread example. We ended up switching to haskell and using heist, which is the same type of deal. The "view first" thing was certainly very irritating, but minor overall compared to other weaknesses in the framework.

comment 13y ago · link · parent

There's nothing unique about lift's template system though, you can get something like that in many languages, potentially while also using a good framework.

comment 13y ago · link · parent

>Can you prove your opinion is objectively correct, or is it just your opinion?

Doesn't that question seem rather non-productive? At least if you asked why he has that opinion you could engage in some sort of potentially constructive conversation on the topic.

comment 13y ago · link · parent

I'm running on an i7 with an SSD already. Our solution was to not use play (or scala for that matter).

comment 13y ago · link · parent

>Compared to redeploying an entire Tomcat/Jetty app, this is several orders of magnitude better.

It is? Are you building a war/ear and copying it to a server to deploy or something? I think every java IDE has support for locally building and deploying within the IDE, which is no slower than play's reloading.

comment 13y ago · link · parent

>Rapid iteration: change the code, refresh the page, and see the change instantly.

I see the play people tout this all the time, and I assume it is in reaction to an assumption of dynamic language people that you have to manually compile every time you make a change. But it is really misleading. You make a change, refresh the page, and wait 10 seconds for it to compile and reload. Iteration speed was just as poor with play as it was with bloated J2EE monsters on jboss.

1
181920
40