|
| platz wrote:
| A fairly low quality article, imho.
|
| The points listed could almost as easily apply to Java or C#
| cryptonector wrote:
| The points listed cannot "as easily apply to Java", and,
| really, not to C# either. You really need a functional language
| to meet the "requirements" listed, which are -from TFA, almost
| at the top-:
|
| > Why? Three reasons: > Functions in the mathematical sense. >
| > No statements, no instructions, just expressions that don't
| ever mutate. Everything returns something. You don't mutate by
| default. > Type-driven programming. > > Start thinking
| generally, in broad concepts, about what kinds of info you're
| dealing with - the inputs, the outputs, the steps - and then
| work down to implementation. Start in the center w/ a little
| implementation and work your way out. Haskell makes illegal
| states unrepresentable. > > You can't do the wrong thing with
| this data because this data can't handle that, it just doesn't
| accept that kind of thing.
| dgb23 wrote:
| Is this the "you can write this in X by implementing a compiler
| for Y"-joke? Or genuine? If so, I find it unfair.
|
| Even at the most fundamental level, the mishmash of
| statement/expression syntax in those languages makes it
| cumbersome at best to compose functions and expressions in the
| style of an FP language. And the more you venture into
| conceptual things like values and functions you're fighting
| those languages left and right to achieve the same _basic_
| semantics.
|
| I'm neither pro nor contra static typing in general and I don't
| really know Haskell, but I think it would be obvious that Java
| and C# don't have the same sophistication, inference and
| expressiveness on the type level as Haskell. When they say
| "make illegal states unrepresentable" they don't mean "write a
| bunch of defensive runtime checks".
|
| Not to bash on Java/C#, they are powerful and very useful. But
| the type of specific benefits the article talks about are not a
| given or even practical in those.
| gavinray wrote:
| I used to think that same thing
|
| I recently found a very smart fellow who has been writing
| translations of a small Scala "expression interpreter" with
| monads and what.
|
| But in Java. I kid you not.
|
| He wrote it in JDK 8 Java (pretty far from Scala)
|
| Then updated with JDK 15 features Java (getting closer)
|
| I made a rough pass at JDK17 Java using records and ADTs
| (sealed types) with pattern match "switch" and the net result
| is an almost verbatim translation.
|
| https://github.com/Randgalt/expressive-java/issues/1
|
| There is one ugly line which JDK18 will fix, "destructuring
| in pattern captures/match".
|
| See "Deconstruction Patterns" at bottom of page here:
|
| https://openjdk.java.net/jeps/405
| zactato wrote:
| I don't think that JEP is part of JDK18 yet.
| bachmeier wrote:
| > You don't mutate by default.
|
| > makes illegal states unrepresentable
|
| Maybe recent versions of Java are different, but I don't recall
| either of those statements applying when I used Java.
| twic wrote:
| Java doesn't force you to do either of those, but it allows
| it, and doing so has been standard programming advice in Java
| for at least a decade.
|
| See item 13, "Favor immutability", in Effective Java, the
| bible of Java programming, published in 2001:
|
| https://www.pascal-man.com/navigation/faq-java-
| browser/java-...
|
| I can't find a concrete citation for "makes illegal states
| unrepresentable" (does anyone know the history of this
| phrase?), but it was certainly part of conversations i was
| having in 2012.
| bachmeier wrote:
| > Java doesn't force you to do either of those, but it
| allows it, and doing so has been standard programming
| advice in Java for at least a decade.
|
| "You can do that" and "enforced by the compiler by default"
| are pretty different.
| marshray wrote:
| "Make illegal states unrepresentable" is usually attributed
| to Yaron Minsky of Jane Street.
|
| This video shows it at 28:02.
| https://blog.janestreet.com/effective-ml-video/
| https://www.youtube.com/watch?v=-J8YyfrSwTk
| odyssey7 wrote:
| The whole idea of OOP is you have mutable data coupled with
| the methods that mutate it.
| cryptonector wrote:
| You can do immutable data structures with OOP. The problem
| is that you can also do mutation.
| zdragnar wrote:
| Compilers / runtimes for most OOP languages don't really
| put the same level of optimization into operations with
| immutable structures as they do with mutable ones,
| because the mutable paradigm is largely how the languages
| are (intended to be) used.
|
| There are exceptions, of course, but you are leaving a
| lot on the table when you try to shoehorn one into the
| other.
| canjobear wrote:
| The biggest advantage of running a Haskell shop is probably that
| it imposes a strong intelligence filter on the devs you hire.
| IshKebab wrote:
| I agree. Two out of the three things listed here you can easily
| do with Typescript. But good luck getting web developers to not
| just use strings for everything.
| teddyh wrote:
| The fact that the product is an astrology product will also
| impose some kind of filter on the people who choose to work
| there.
| twic wrote:
| Maybe that's why they could only hire Haskell devs.
| _query wrote:
| Haskell is really an underrated super power for building backends
| and web apps. The ecosystem has improved quite a lot over the
| recent years. With the Haskell Language Server and the Haskell
| Plugin for VS Code there's now really nice editor support. The
| language itself is also improving at a good pace, e.g. the latest
| release of GHC (The haskell compiler) added support for dot-
| notation, so you can now write `someValue.someField` as you might
| know from other languages.
|
| If you're curious about giving it a try and are doing web dev,
| check out IHP, haskell's largest web framework:
| https://ihp.digitallyinduced.com/ (Disclaimer: I'm founder of the
| company that makes IHP)
| toomanydoubts wrote:
| I've been getting lots of ads about IHP on reddit lately. The
| ads are really bad, which led me to believe IHP would be of
| equally bad quality, but looking at IHP homepage now I'll just
| have to try it out sometime. Now, I have some questions. As a
| user, why should I use IHP instead of Yesod or Servant? Can I
| create rest and especially graphql apis or is it more focused
| on building old-school server side rendered pages?
| _query wrote:
| Thanks for the feedback on the ads! We've been experimenting
| a lot with different ad formats recently. I'll make sure this
| is fixed. (Update: Fixed now, thanks again for the honest
| feedback)
|
| In a comparison between IHP and Yesod I think that IHP is
| designed for people that have only very little to no haskell
| experience. IHP brings a lot of conventions and code
| generators to get you up and running very quickly, while
| Yesod gives you more flexibility (flexibility might be more
| challenging when you're just starting out with haskell. E.g.
| what DB library do you want to pick? In Yesod you have many
| options, in IHP we'll provide one out of the box). Check out
| the IHP documentation and compare it to the Yesod docs,
| you'll quickly see the difference :) Also if you want to
| check out some reviews of people already using IHP, you can
| find a few longer ones on our G2 page
| https://www.g2.com/products/ihp/reviews
|
| > Can I create rest and especially graphql apis or is it more
| focused on building old-school server side rendered pages?
|
| At the start IHP was focussed a lot on server-side rendering.
| Now you can also use it for building REST APIs. GraphQL is
| not yet supported, but it's coming in the future.
|
| We're also right now working on a generic REST API layer with
| a bundled JS SDK. It will allow you to query your database,
| create and delete models and keep everything in sync with a
| realtime sync engine.
|
| Here's a JS code example: const tasks =
| await query('tasks') .orderBy('createdAt')
| .fetch()
|
| On the backend we use Postgres Row-level-security Policies to
| make sure that a user can only access his own data.
|
| Here's a demo react component that uses the new JS APIs:
| https://github.com/digitallyinduced/ihp-datasync-
| demo/blob/m...
|
| Docs are still in progress, but here's a draft https://github
| .com/digitallyinduced/ihp/commit/39baa4aa23cc6... :)
| kodefant wrote:
| To me, IHP provides so many great features for making type-
| safe robust web apps, I have forgotten about GraphQL.
| ramesh31 wrote:
| >If you're curious about giving it a try and are doing web dev,
| check out IHP, haskell's largest web framework:
| https://ihp.digitallyinduced.com/ (Disclaimer: I'm founder of
| the company that makes IHP)
|
| Something ironic about getting a 502 from your domain right now
| _query wrote:
| Haha yes :) Sorry, the IHP website is hosted via
| https://ihpcloud.com/ (like Heroku but for IHP) and the
| system just crashed because of too much activity (unrelated
| to the HN traffic, mostly too many deployments at the same
| time). We're about to roll out a new more stable system in
| the next days that fixes the root cause of the downtime
| today.
| pmarreck wrote:
| IHP looks like an impressive work, I'm seeing a lot of the
| kinds of things that drew me from Ruby/Rails to Elixir/Phoenix
| here, and all of those things are good... plus I love how the
| type safety is basically all implicit now, which seems like the
| best of both worlds- ruling out additional classes of bugs but
| without needing to be explicitly verbose all the time about
| types.
|
| Quick question - when you change the schema def, does it
| generate a schema diff automatically and run that? What if you
| have to do some more complex things like add triggers or stored
| procs (such as might be necessary if you use Postgres' fulltext
| search features, which I am wont to do)?
|
| Second question- Is there something I could read to catch up
| with what's happened to the Haskell language over the last 5-10
| years or so, since I looked at it last?
| quantified wrote:
| Something lovely here about leveraging formal correctness for
| delivering astrology.
| abeppu wrote:
| On their front page:
|
| > Most horoscopes ask what month you were born. Co-Star asks
| what minute.
|
| > Access to astrology this accurate has historically been
| restricted to those with access to personal astrologers--now
| these predictions can be anyone's.
|
| I mean, anyone can _ask_ what minute you were born. But what on
| earth can "accurate" mean in this context? I'm sure there's
| some modern tech we can use to measure your skull with great
| precision and detail, but I'm guessing that doesn't improve the
| predictions of phrenology.
| plafl wrote:
| If it compiles your predictions are bug free
| pxc wrote:
| Mathematically-inclined people surviving by calculating
| outstandingly accurate and precise charts for producing
| superstitious bullshit is an ancient tradition
| 3maj wrote:
| The Day trading quant gets _cold sweats_ as he reads this.
| pxc wrote:
| this made me laugh out loud in public
| uptownfunk wrote:
| Perhaps you are referring to the traditional sun-sign
| astrology found in tabloids/magazines? There are claims that
| you can get much more precise by looking at ascendant-based
| astrology which varies down to the minute and lat/long of the
| place you were born. Or are you referring to both? Are there
| sources out there in the literature proving/disproving modern
| Astrology? There is this article on Gauquelin's Mars effect
| for instance - https://en.wikipedia.org/wiki/Mars_effect
| dudeinjapan wrote:
| One of my favorites is Jantar Mantar
| https://en.wikipedia.org/wiki/Jantar_Mantar
| pphysch wrote:
| Two non-surprises here:
|
| > We currently have exactly two backend engineers. A single
| Haskell engineer can support a 2:3+:1 data:FE:BE developer ratio
| and still have free BE time.
|
| 1) That they have 1-2 Haskell developers.
|
| 2) That backend is very straightforward once you separate it from
| data engineering and frontend, because you don't have to deal
| with hardware or wetware (pesky "side effects") like those other
| poor sods. This applies to virtually any popular backend
| language.
|
| Yet another confirmation that pure functional langs work great
| when its just one or two buddies working on a "pure programming"
| project, but evidence remains scant of their real world utility
| beyond that.
| avgcorrection wrote:
| First they said that functional programming is only used for
| toy/proof of concept/academic things. And that's fine, to the
| extent that that is true. There is a sort of real
| world/academenia dichotomy.
|
| But now you're deriding functional programming because it is
| used on... a regular old boring backend. Used to power a non-
| FP-related domain (to dismiss the "I used FP to implement
| another FP language" critique...). On an ostensibly real-world
| application. And you contrast this backend with "real world
| utility"...
|
| This is quite confusing.
| tadfisher wrote:
| > Yet another confirmation that pure functional langs work
| great when its just one or two buddies working on a "pure
| programming" project, but evidence remains scant of their real
| world utility beyond that.
|
| We (Mercury) have 60 backend engineers working on a monolithic
| Haskell backend. So at least there is one counterpoint to your
| hypothesis.
| pphysch wrote:
| What does your onboarding process look like for Haskell
| engineers? Ballpark time-to-first-master-commit for new
| hires?
| DesertVarnish wrote:
| I'm another Mercury employee. When I joined there wasn't
| much of a specific onboarding process at all, beyond being
| given a few simple tickets to work on and pointed to some
| documentation.
|
| I had written a very small amount of Haskell before, but
| IIRC correctly I think I made my first commit only a few
| weeks after joining. In general even people without an
| existing strong FP background seemed to become productive
| pretty quickly.
| mjh2539 wrote:
| > Yet another confirmation that pure functional langs work
| great when its just one or two buddies working on a "pure
| programming" project, but evidence remains scant of their
| utility beyond that.
|
| Evidence is abundant if you look for it. FB, Microsoft, and
| Standard Chartered all have active internal haskell projects.
| taeric wrote:
| Like all evidence, it is actually easy to find both sides.
| Notably, I have yet to come across a project in clojure,
| Haskel, or scala that wasn't abandoned as soon as the major
| advocate for that language left the group.
|
| Sad in the cases where it was a well done project.
| Frustrating when it was bursting at the seams.
| whateveracct wrote:
| The main reason for that phenomenon is it's more personally
| advantageous to rewrite than to learn Haskell and extend
| what's there.
|
| Haskell advocate quits? Blame them for selfishly using a
| toy language (they're gone anyways - who is gonna
| disagree?), and save the day by spending a long time
| reimplementing an MVP subset of what they already did.
| Congrats - you're a hero! The end product has less
| functionality, but at least you didn't have to do something
| actually hard like learn Haskell and work with Someone
| Else's Code.
|
| I've seen this happen multiple times. For shame - and yes
| people did get promotions for it. Pathetic.
| ramesh31 wrote:
| >The end product has less functionality, but at least you
| didn't have to do something actually hard like learn
| Haskell and work with Someone Else's Code.
|
| But did the _business_ need all of that functionality?
| Rewriting a subset of an application that is far more
| maintainable and cost effective in the long run can be a
| huge win. I am currently rebuilding an application full
| of intractable bugs and proprietary DSLs that was
| implemented in Salesforce with lots of bells and whistles
| that nobody wants or needs to be a simple Golang /Mysql
| app hosted on AWS. Yes, it is a tiny subset of the
| current functionality. But it solves the business case
| and will save millions of dollars per year in Salesforce
| fees while simultaneously making the user experience an
| order of magnitude simpler and allowing faster
| onboarding.
|
| Engineers allowed to run free can often times spend an
| inordinate amount of time building things out that no one
| really asked for. Your Haskell backend was probably a
| thing of pure beauty from a programmers point of view.
| But an expensive liability to the business.
| whateveracct wrote:
| > But did the business need all of that functionality?
| Rewriting a subset of an application that is far more
| maintainable and cost effective in the long run can be a
| huge win.
|
| It was needed enough that the rewrite (which was slow)
| had to delay release and the legacy software had to be
| kept alive well past its sunset date (and plenty of
| people jetted by then.) Because the business had to keep
| the lights on!
|
| The missing functionality at least was said to be missed
| by the business folks who made use of it. "If only we had
| feature X" definitely was said.
|
| There wasn't anything too beautiful about the Haskell. It
| was mostly systems work. But incrementally evolving and
| improving would've definitely be cheaper long term than a
| rewrite .. but it does require people to learn Haskell,
| which seems to be a nonstarter for many. If people don't
| wanna, they don't wanna.
| taeric wrote:
| That would be the sad case. I have also seen the case
| where the code was impenetrable and did not at all lend
| itself to extension.
| Barrin92 wrote:
| I'm pretty sure Nubank has for years and continues to rely
| heavily on Clojure. (to the point where they acquired
| Cognitect)
| taeric wrote:
| Right, I meant my point to be that you can find evidence
| on both sides. Far as I can see, language is not a
| predictor of success.
|
| Having an advocate for a program is a predictor. That
| advocate doesn't have to be a developer.
| hota_mazi wrote:
| I've always been fascinated by the fact that these claims are
| always completely unfalsifiable.
|
| "A lot of companies use this in
| internal projects but since it's internal, we can't show
| you".
|
| It reminds me of "I have a girlfriend but she goes to another
| school".
| mbesto wrote:
| I've tech diligenced 200+ software companies and I've seen
| Haskell twice and Clojure once. The two that were using
| Haskell had to drop the project and rewrite because they
| couldn't find enough developers.
|
| I have zero problems with the technical capabilities of
| functional programming languages, but it's simply not a
| smart decision to use them in for profit businesses writing
| CRUD apps. It simply doesn't make economic sense. When you
| get to scale and need to write then it
| starts to make more sense.
| mjh2539 wrote:
| https://engineering.fb.com/2015/06/26/security/fighting-
| spam...
|
| https://www.reddit.com/r/haskell/comments/phooqo/haskell_ro
| l... https://www.reddit.com/r/haskell/comments/oee437/job_a
| d_seni... https://www.reddit.com/r/haskell/comments/nug8mw/
| haskell_job... https://www.reddit.com/r/haskell/comments/nn
| 11sm/haskell_job... https://www.reddit.com/r/haskell/commen
| ts/n642ve/haskell_dev...
|
| https://www.reddit.com/r/haskell/comments/8io3uk/job_work_o
| n...
| hota_mazi wrote:
| So... an article from six years ago, and then a few open
| job reqs.
| twic wrote:
| I've spoken to people who have been through that
| department at Facebook, and they report the scale of use
| of Haskell is wildly exaggerated.
| bojo wrote:
| I mean, what are those of us in this category supposed to
| do?
|
| For the last 5 years I have 7 developers that have been
| working on internal applications in Haskell for an
| enterprise company that I am not able to show you due to
| legal reasons. We have a small open source library or two
| out there, but they are not even remotely representative of
| how deep our development iceberg really is.
| [deleted]
| pphysch wrote:
| Do any of these projects have more than 1-2 active
| maintainers?
| bidirectional wrote:
| None of them are individual projects, all of those
| companies have several projects in Haskell. Standard
| Chartered, for one, have their own custom implementation of
| Haskell and it is used by dozens of developers across
| different projects.
| dllthomas wrote:
| IIUC it's their own custom implementation of something a
| lot like Haskell, with the compiler implemented in
| Haskell.
| samhh wrote:
| It's called Mu. It's strict and has a few other quirks.
| There are a few different teams using it for different
| projects.
|
| Source: Used to work there.
| named-user wrote:
| I think it's generational.
|
| I believe we are limited by our own experience, a lot of
| software is built upon the idea that problems are solved
| through procedural steps rather than a series of
| transformations.
|
| This does not lend itself to thinking in a way that aligns
| nicely with functional programming.
|
| Future generations will naturally think in ways unfathomable to
| you and I, and this will cause a shift in the fundamental
| approaches to software development.
| ritchiea wrote:
| I think it's subjective. I learned Haskell early on in
| university and I've learned Lisps and it still feels like
| extra work to reason about programs or model domains in
| functional languages.
|
| I believe functional programming advocates when you guys say
| it works better. But I only believe it works better for you.
| In my experience there's a minority of people who find
| functional programming to be a powerful paradigm shift but
| for most developers functional programming either doesn't
| resonate or resonates at the level of an academic exercise
| that helps you think better about writing code but best
| remains an academic exercise.
| grumpyprole wrote:
| It can be extra work to reason about the performance and
| efficiency of functional programs, such is the case with
| higher level languages. But modelling the domain is _far_
| easier. I can solve difficult problems using Haskell, e.g.
| writing a specialist DSL compiler targeting a GPU. I 'm
| just not smart or patient enough to solve such problems in
| C/C++ or Java, although I do concede that many can.
| bcrosby95 wrote:
| I broadly agree. I actually think most people are most at
| home in the procedural domain, and most just write
| procedural code in OOP languages. Which is hard to do in an
| FP.
| pphysch wrote:
| Last time I checked, everything is still running on von
| Neumann/Harvard CPUs. Did I miss a major revolution in
| computing?
| marcosdumay wrote:
| Yes, nowadays we have those machines, called computers (or
| automatic computers if you need the older name for
| reference), that can take software made for one
| architecture, no matter how unreal, and turn it into
| software made for another architecture.
| pphysch wrote:
| Could you share a Haskell compiler that produces output
| that can execute on a real non-von Neumann/Harvard
| architecture?
| gmfawcett wrote:
| Forgive the tangent, but your comment reminded me of item
| #52 on the venerable "Things to say when you're losing a
| technical argument" list. :)
|
| http://web.archive.org/web/20050131033632/http://www.skirsc
| h...
| pphysch wrote:
| Yikes.
| named-user wrote:
| Yes
| pphysch wrote:
| Please elaborate.
| mixedCase wrote:
| Compilers.
| pphysch wrote:
| Which (Haskell) compilers that target actually-existing
| hardware do not output _procedural_ bytecode?
| mixedCase wrote:
| That is the point.
| whateveracct wrote:
| Evidence does not remain scant. For instance - ever used
| Starbucks Rewards? Congrats, you used Haskell software built by
| more than "two buddies." Ever shop at Target? Congrats, the
| inventory was likely in the store to fulfill your demand in
| part thanks to Haskell software built by a team.
|
| However, a large engineer org that brings in senior non-
| Haskeller engineers/managers/leadership is bound to run into
| political troubles imo. Those types tend to blame Haskell and
| use it as an excuse for rewriting and re-orging - hence giving
| them newfound power. This isn't FUD or a strawman. This is
| observed behavior of many "respected" "old heads" I've had to
| work with/for.
|
| That's just my experience from 3 different companies lol :) You
| can build software at any scale with Haskell - you just have to
| actually like and want to use Haskell for its cultural and
| technical benefits. Sadly, a complainer at the top of the org
| chart who can't even read Haskell code can easily come in and
| force Haskell out. That's just facts.
| alexfrydl wrote:
| Honestly my first thought when I saw the title "why we use
| Haskell" was "because you have one engineer and they like
| Haskell?" I suppose I was wrong. It was two.
| claytonjy wrote:
| I appreciate and agree with the attitude/approach here.
|
| I suspect the author may be a bit removed from modern python, as
| the community is increasingly taking a similar stance. Python is
| not Haskell, but Python in 2021 with tools like type-hints, mypy,
| (frozen)dataclasses, Pydantic, etc. is trying to address at least
| the latter two points here (type-driven & illegal-states-
| unrepresentable). I'm not aware of ways to enforce function
| purity in python (do any linters complain about input
| modification or out-of-scope references?), but I try to make
| functions as pure as possible regardless of language or domain
| anyways.
|
| I don't mean this as a flamewar, Haskell seems like the right
| choice for OP. I love how a language like python is making more
| of these benefits available to a wider audience and I wish more
| folks embraced these recent advances.
| named-user wrote:
| >tools like type-hints, mypy, (frozen)dataclasses, Pydantic,
| etc. is trying to address at least the latter two points here
| (type-driven & illegal-states-unrepresentable)
|
| At some point you have to admit to yourself that it's the wrong
| tool for the job, when is this going to be?
|
| Dependency/environment management is poor as well given how
| popular the language is. I believe it's popularity is similar
| to that of PHP in the past; flooded with carefree users.
|
| I would strongly advise against using python for anything other
| than PoC/experimental endeavours.
|
| It's a scripting language, and should be used as such.
| gmfawcett wrote:
| I don't know. I like Haskell, but practically I would still
| choose a dynamic language "with benefits" over Haskell for BE
| development. [1] For example, Python frameworks like FastAPI
| can enforce type discipline at the system boundary, and
| frankly it feels like a development sweet-spot. Rigour at the
| API level, but fast-and-loose reasoning can proceed as normal
| in the implementation.
|
| It's a worse-is-better approach, to be sure, but it has a
| very appealing effort:result ratio.
|
| [1] with the normal caveats -- every project is different,
| everybody's notion of a "backend" is different, etc. Haskell
| might be the sanest solution to some backend challenges.
| named-user wrote:
| FastAPI is hard to contend with for anything marginally
| complex, without having to dig deep in its internals.
|
| If you want performance, or to apply more rigorous (read:
| enterprisey) development practices, you really are better
| off looking elsewhere.
|
| However, you can get a Data Science python developer to
| front their code behind an API with minimal ceremony.
|
| Type safety does not exist in Python. Type hinting does not
| solve this problem, neither does Pydantic. These are
| bandaids for huge shortcomings of using the wrong tool for
| the job.
| mrtranscendence wrote:
| Just continually _saying_ Python is the wrong tool for
| the job doesn 't cut it. I've gotten a lot of mileage out
| of type hints in Python and have caught my share of bugs
| statically, so I disagree with your contention that it's
| merely a "bandaid for huge shortcomings". It's a helpful
| tool that serves a purpose.
|
| You could pick at every tool, every language. What's
| better than Python at (since you brought it up) data
| science? Julia? That's hardly any more type safe, if
| that's an issue for you. Haskell? Good luck getting non-
| CS types to buy in to the restrictions, and good luck
| porting everything you need. R? Slower than Python, even!
| I mean, I dunno, if you have something in mind that's
| better _in every way_ than Python then I 'd love to hear
| it.
| gmfawcett wrote:
| Sure, but there's a continuum at play here. Haskell
| leaves some correctness on the table, right? -- you
| should be using Idris 2; or better yet, proving your API
| in Coq and extracting the code. From some perspectives,
| Haskell is the "worse" in "worse is better".
|
| Personally I find python-is-wrong arguments to be a bit
| naive. "It's a crappy language that's only good enough to
| build prototypes..." -- like YouTube, for example? :)
| Ultimately, smart developers are smart, and can get work
| done with whatever tools they have at hand.
| fiedzia wrote:
| Take computer away from them and see how far they'll go.
|
| Tools matter. However the community and ecosystem behind
| Python makes it extremely hard to beat at many games.
| gmfawcett wrote:
| LOL, I agree that YouTube would be hard to build if you
| only had a hammer and chisel. :P
| claytonjy wrote:
| I agree and I really like that way of framing it; I want
| interfaces and contracts strong enough that I don't have to
| care about the implementation.
| claytonjy wrote:
| I work in data science and engineering, so not using python
| is not really an option. I'd love to use Julia and Rust
| instead, but the ecosystems and users aren't there yet.
|
| Python continues to earn its reputation as the second-best
| option for most problems.
| named-user wrote:
| I agree absolutely.
|
| It's always a matter of choosing the least worst solution
| with Python, and additionally patching over shortcomings of
| the language with afterthought-tooling.
| CraigJPerry wrote:
| >> Python continues to earn its reputation as the second-
| best option for most problems
|
| Never heard that line before but it resonates with me.
| dunefox wrote:
| > I'd love to use Julia and Rust instead, but the
| ecosystems and users aren't there yet.
|
| https://github.com/JuliaPy/PyCall.jl
| https://github.com/JuliaInterop/RCall.jl
| Orou wrote:
| > I would strongly advise against using python for anything
| other than PoC/experimental endeavours.
|
| I agree with your points, but this seems to lean a bit too
| far the other way. Yes, Python has plenty of limitations and
| cases where there are better choices in programming language.
| But saying that it shouldn't be used in real production
| systems when there are so many examples of it being used
| effectively for precisely that seems a bit hyperbolic, no?
| It's like saying Javascript shouldn't be used in production.
| romero-jk wrote:
| At least JS can be 50X faster than Python and it has TS.
| ModernMech wrote:
| > It's like saying Javascript shouldn't be used in
| production.
|
| I mean... is that such an unreasonable point of view?
| toomanydoubts wrote:
| No matter how many type hints you put in your python code,
| haskell type system is on another level altogether. I honestly
| believe every developer should get to experience writing some
| haskell code at some point in their lifes to really understand
| what I'm talking about.
| gen220 wrote:
| > do any linters complain about input modification or out-of-
| scope references?
|
| I know Instagram was experimenting with something similar to
| this a couple years ago ("Python strict modules").
|
| It might be possible to implement function purity with a
| decorator. (Kind of like declaring something "safe" in Rust).
|
| Definitely agree that Python is becoming more amenable to
| functional style programming over time. And it's great!
| ianandrich wrote:
| > It might be possible to implement function purity with a
| decorator. (Kind of like declaring something "safe" in Rust).
|
| Two parts to this. 1: Does it mutate variables. 2. Does the
| code have side effects.
|
| 1: def no_mut(func): @functools.wraps def new_func( _args,
| *kwargs): new_args = tuple(copy.deepcopy(arg) for arg in
| args) new_kwargs = {k, copy.deepcopy(v) for k, v in *kwargs
| return func(_ new_args, *new_kwargs) return new_func
|
| For the second point, gevent seemed to have a trick to
| identify side effecting code.
| 8589934591 wrote:
| Are there examples of moving from Python to Haskell? Would love
| to read and evaluate such options since I'm in dire need of
| moving away from Python to a typed language and Haskell seems
| like an interesting choice.
| LeonidasXIV wrote:
| Not from Python to Haskell but Thomas Leonard[1] has a very
| nice series of blog posts about migrating 0install away from
| Python to OCaml, of which many points also apply to Haskell
| which he evaluated as a choice as well.
|
| [1]: https://roscidus.com/blog/blog/2013/06/09/choosing-a-
| python-...
| mpweiher wrote:
| The writeup appears to be about as well-founded as the domain.
|
| "Increased abstraction means that you can write things much
| quicker and more simply than in another language."
|
| Except for any other kind of higher level language.
|
| > [Haskell is much more bullet-proof than] IF NATALPLANET ==
| "MARS"
|
| As is any other non-stringly-typed language, so everything other
| than Tcl. And even Tcl is misunderstood, it's actually pretty
| awesome for its intended purpose. And of course you can write
| stringly typed code in Haskell just as much as you can in any
| other language.
|
| and so on.
| projektfu wrote:
| Comparing to Python and Javascript, referencing an unused name
| in source without reaching it in your execution path will not
| cause an error. a=4 3+a 3+a or
| 3+b
|
| in a strongly-typed language, that would break compilation. So,
| Java and C will not compile those, either, but the article
| doesn't go into other cases where Haskell types are more useful
| for preventing various errors, such as Data.Result, which can
| either be a result of the type you expect or an error type, and
| which the compiler requires you to handle both cases. I think
| the write up would have benefited from some of the more
| advanced cases like this.
| mpweiher wrote:
| This isn't due to static typing (you appear to be mixing up
| strong vs. static typing).
|
| This will also not compile in Smalltalk.
|
| Nothing to do with static typing at all.
| igouy wrote:
| > [Haskell is much more bullet-proof than] IF NATALPLANET ==
| "MARS"
|
| And perhaps there might be something like a Python _Enum HOWTO_
|
| https://docs.python.org/3.11/howto/enum.html
| samhh wrote:
| I'm not familiar with Python, but if those are traditional
| enums and not sum types then you're missing out on a lot in
| terms of domain modelling.
| amznbyebyebye wrote:
| I see astrology as basically "folk data science". You make
| observations and try to find correlations (not causation, though
| some ancient literature does attempt to explain it). One simple
| one is Mercury goes into retrograde motion and takes down Meta
| with it.
|
| You can model intrapersonal dynamics (basically found by looking
| at findings between positions of transiting bodies and those of
| the natal chart, namely the positions calculated at the
| time/place of the individual's birth). For example the current
| position of Jupiter (which symbolizes growth/expansion) is now
| conjunct an individual's natal midheaven (represents career/how
| you are seen in society) and all of a sudden this person is being
| recognized in a very positive way by their community or
| workplace.
|
| You can also model the interpersonal dynamics, found by looking
| at the effects of just the transiting planets alone, say
| transiting Mars conjuncts the North Lunar Node or Pluto and all
| of a sudden you have these really violent transformational events
| that erupt. Maybe mass shootings, natural disasters etc.
|
| The other interesting thing about astrology is it stands to unify
| many disparate concepts together. For example Jupiter is at the
| same time connected to the liver, to growth, to happiness, to
| biology, etc. if I recall correctly. Where else could you find
| this idea of unifying together seemingly unrelated things into
| the notion of a planetary symbol.
|
| One thing I find sorely lacking is the complete lack of any
| statistical rigor applied to the predictions/indications given by
| astrological readings.
|
| I do find it fascinating that co-star is throwing technology and
| data science to the problem. It may not be far off to see them
| publishing findings that actually meet the level of rigor to at
| least show statistically significant correlations. I don't
| practice or believe these things personally, but my ancestors
| used to try to help their communities understand their problems
| better using tools like ancient Indian astrology.
| brokencode wrote:
| Personally, I think astrology today is just an easy way to make
| money off of folks who don't know any better.
|
| While it would surely be one of the most incredible scientific
| discoveries in human history to prove that the normal motion of
| objects in the solar system can somehow affect people's lives
| through some unknown force, it is incredibly unlikely.
|
| To claim otherwise and sell some kind of product or predictions
| based on astrology is dishonest.
| amznbyebyebye wrote:
| On average literacy as to what astrology is in fact growing
| not shrinking. This is in particular due to social media and
| YouTubers who get into the nitty gritty details of birth time
| based astrology.
|
| You don't need to prove the causative relationship in many
| cases. Look at modern ML where "why does this model predict
| the outcome so well" is generally an open research question.
| ahmedfromtunis wrote:
| Off topic!
|
| I'm really curious about how hners think/feel about astrology. Do
| you "believe" in it or does it help in any meaningful way?
|
| I grew up thinking these kind of things are for the "uneducated"
| but I'm surprised by how many smart people I meet nowadays who
| really care about this stuff. So, I'm really curious!
| oxfeed65261 wrote:
| I think of astrology, like tarot, as a storytelling tool. For
| myself, an astrology or tarot reading gives a narrative which I
| can consider and possibly act upon. For flattering or welcome
| aspects of the reading, do I actually manifest the desirable
| characteristics? Could I be more like these aspects of the
| reading? For unflattering/unwelcome aspects, the opposite.
|
| Of course, this works just as well with a randomly shuffled
| tarot deck, or with a random astrological reading (I don't
| think that there is anything special about the astrological
| reading which corresponds to my date of birth).
|
| I haven't written fiction in a long time, but I also think it
| might be interesting to use such readings to develop fictional
| characters or plots.
| _bohm wrote:
| I place zero stock in it as far as decision making or
| understanding myself/others goes, but it also doesn't really
| make me angry in the way that it seems to for a lot of other
| people. I think it's often quite fun to compare astrology
| charts or ask someone their sign as an icebreaker when getting
| to know them, etc.
| whatshisface wrote:
| People get mad about astrology because it's a clear cut case
| of rational people abusing less rational people, like Q-anon.
| _bohm wrote:
| Is it that clear-cut? My impression is not that astrology
| as a practice has a rigid hierarchical structure, nor that
| the people disseminating horoscopes and the like do not
| believe it themselves.
| whimsicalism wrote:
| I think it can be really damaging and there's a substantial
| proportion of the population that actually believes it and
| spends a substantial amount of time obsessing over it.
|
| I hear the couple next door to me in SF get in shouting
| matches through the wall about how she doesn't feel like he
| takes her seriously because he doesn't believe in astrology,
| about how there are some things that science doesn't
| understand, etc. etc. And she's like a PM at Stripe or
| something.
| _bohm wrote:
| I feel you, but at the end of the day I don't think
| astrology as a belief system is any wackier or more harmful
| than most mainstream religions. And my capacity for holding
| a grudge against people for having beliefs that lack an
| empirical basis is not very high.
| bobthechef wrote:
| > I don't think astrology as a belief system is any
| wackier [...] than most mainstream religions.
|
| Statements like these are problematic. Not only are there
| meaningful differences between religions that make them
| incommensurate in this context (e.g., a Catholic, while
| acknowledging that some glimmers of greater or lesser
| truth exist in all religions, will regard much of them as
| erroneous and even superstitious), but it seems you
| haven't done the philosophical due diligence here to make
| a sensible comparison.
|
| For example, we have no reason to suppose that the
| relative positions of the planets has any effect on how
| things pan out. And additionally, from a Catholic
| perspective, not only is astrology generally taken to be
| superstitious (on account of its irrationality), but the
| impulse behind astrology is also taken to be evil. From
| the Catechism of the Catholic Church:
|
| "All forms of divination are to be rejected: recourse to
| Satan or demons, conjuring up the dead or other practices
| falsely supposed to 'unveil' the future. Consulting
| horoscopes, _astrology_ , palm reading, interpretation of
| omens and lots, the phenomena of clairvoyance, and
| recourse to mediums all conceal a desire for power over
| time, history, and, in the last analysis, other human
| beings, as well as a wish to conciliate hidden powers.
| They contradict the honor, respect, and loving fear that
| we owe to God alone" (CCC 2116)[0].
|
| (N.b. the catechism is not a defense of these beliefs. I
| cite it only to show the Catholic position. Defenses can
| be found elsewhere, as well as pedagogical treatments
| like those in the Summa[1].)
|
| The positions of the Church are rigorously defended over
| at least two millennia, some before that where natural
| theology and philosophy are concerned (the _existence_ of
| God, for example, is knowable through unaided reason; the
| divinity of Jesus, on the other hand, requires faith in
| the sense that while the totality of evidence may be very
| strong in favor of that belief, it is not fully deducible
| in the way philosophical arguments for the existence of
| God are). To compare astrology to that intellectual
| tradition (I ignore here the petty superstitions
| particular Catholics might entertain) is ludicrous.
|
| And part of due diligence is also an understanding of
| what constitutes an "empirical basis" and where and how
| it is an appropriate to draw on empirical observation.
| For example, does the claim "a belief P is reasonable if
| and only if there is an empirical basis for it" itself
| have an "empirical basis"? If so, in what way?
|
| [0] https://www.vatican.va/archive/ENG0015/__P7E.HTM
|
| [1] https://www.newadvent.org/summa/3092.htm
| _bohm wrote:
| The point of my comment really wasn't to denigrate
| anyone's belief system or to prop up empirical basis as
| an absolute standard for establishing the veracity or
| value of a claim.
|
| The parent commenter expressed concern that people
| holding these unsubstantiated belief systems as truth was
| inflicting real harm to society. My point was to say that
| if this is a real concern, why are we singling out
| astrology as a punching bag? Basically all major
| religions entail beliefs which are unsubstantiated by
| empirical evidence. Do we as individuals really have the
| capacity harbor ill will towards anyone who chooses to
| believe things outside what can be verified empirically?
| I don't!
|
| Your belief system may be incompatible with Astrology,
| and it may possess a richer intellectual tradition than
| Astrology, but this alone is insufficient to convince me
| that the faith-based beliefs of one system are inherently
| superior or more true than the other.
| toqy wrote:
| > there's a substantial proportion of the population that
| actually believes it and spends a substantial amount of
| time obsessing over it.
|
| Is this actually substantiated?
| twic wrote:
| I came across this interesting post touching on Haskell just
| recently:
|
| https://www.drmaciver.com/2015/04/on-haskell-ruby-and-cards-...
| AreYouSirius wrote:
| ASTROLOGY.............
| stefantalpalaru wrote:
| And you thought being associated with cryptocurrencies was bad
| :-)
| StefanWestfal wrote:
| I am interested in functional programming. Without a CS
| background I was wondering, if Haskell can provide these
| guarantees, why is it not more adopted?
|
| If, on an enterprise scale, you can avoid the majority of bugs,
| would that not be a clear win?
| dudul wrote:
| It is hard to hire developers with Haskell XP since not a lot
| of companies use it. And not a lot of companies use it because
| it's hard to hire for.
|
| This vicious cycle exists for a lot of very good languages.
| dunefox wrote:
| > why is it not more adopted?
|
| "We use Java here. We have always used Java here and we will
| always use Java here. We're a Java shop. No other languages
| exist." My personal experience with companies.
|
| > If, on an enterprise scale, you can avoid the majority of
| bugs, would that not be a clear win?
|
| Yes, but then you wouldn't be using Java.
| nesarkvechnep wrote:
| Yeah... the Java monoglots.
| [deleted]
| frozenport wrote:
| >> Co-Star is built by a small team of thirty.
|
| LOL thats giant. How much does it cost to run the show? 30 x
| $100,000 for an astrology app?
| bojo wrote:
| I have strong feelings against astrology myself, yet I find it
| frustrating _that_ is the HN takeaway here, and not the fact
| that there 's a successful company making enough money to fund
| 30 people's salaries and is written in what a lot of us
| consider an interesting functional programming language.
| dang wrote:
| That's doesn't seem to be an accurate description of this
| thread. Maybe look again?
| dang wrote:
| " _Please don 't post shallow dismissals, especially of other
| people's work. A good critical comment teaches us something._"
|
| https://news.ycombinator.com/newsguidelines.html
| TheMagicHorsey wrote:
| Astrology seems like such a strange thing for a Haskell developer
| to be spending her time on. I wouldn't think twice about it if
| the back-end was written in Python, but I just find it strange
| that she's sharp enough to be a Haskell pioneer, but still thinks
| the positions of stars influences what approach you should take
| in a relationship.
| nybble41 wrote:
| You probably don't need to believe in astrology to work there.
| Perhaps she just feels that this is a simple and mostly
| harmless way to separate some irrational individuals from their
| money. Which, on the whole, is probably a net benefit to
| society: If they weren't spending their discretionary funds on
| $20 astrology-themed in-app purchases they might instead put it
| toward something _really_ dangerous.
| 6gvONxR4sf7o wrote:
| This is illegible with that background (in portrait mode on an
| ipad pro).
| adhoc_slime wrote:
| same with chrome 95.0.4638.69. whatever they intended it to
| look like, they failed.
|
| edit. Its a dark mode issue, styling not being applied to the
| background rendering
| mpweiher wrote:
| Lucky you.
| 0xcoffee wrote:
| On desktop the background follows the mouse. I couldn't focus
| on anything else, I move my mouse around while I read.
|
| If the author is reading these, please consider using a static
| background.
| babelfish wrote:
| I couldn't finish anything past the first paragraph because
| the background made me nauseous
| pxc wrote:
| I only see that weird background stuff if I have my global
| dark mode browser extensions on
|
| when I turn that off, I can't see any background effects at
| all
| dudeinjapan wrote:
| Sh*t... the horoscope I've been using all these years doesn't
| have functional correctness. So THAT's why I've made all the
| wrong decisions in my career and love life.
| teddyh wrote:
| Forgive me if I don't want to read anything written by someone
| making an _astrology_ product. I may be open-minded, but I have
| limits where it comes to people who I _know_ are trying to
| influence me into believing stupid false things to their benefit.
|
| I mean, if they're fine with claiming that astrology is real to
| enrich themselves, why should I believe anything else they say?
| onion2k wrote:
| _Forgive me if I don't want to read anything written by someone
| making an astrology product._
|
| Typical Capricorn.
| odyssey7 wrote:
| Many consider astrology to be a creative and self-reflective
| process. Definitely would want to hear technical ideas from
| that kind of person. In any case, it's up to the reader to
| decide where they will look for ideas and what they find
| valuable.
| teddyh wrote:
| In the current climate of censoring "misinformation",
| astrology and its ilk should have been the first to go.
| Propagating superstitions and encouraging magical thinking
| is, if _anything_ is, a destructive force on critical
| thinking.
| ashtonkem wrote:
| Eh. Astrology is obviously bullshit, but on the whole it's
| much less harmful than other forms of misinformation. If
| we're going to spend public and private credibility
| haggling over misinformation, I'd rather focus on the forms
| that have a much higher body count. I'm fine with leaving
| astrology in the category of "not subject to any
| moderation, but openly mocked by other commenters whenever
| it comes up".
| teddyh wrote:
| Sure, there's a scale to these things:
|
| https://twitter.com/abbieasr/status/1312512066071060480
|
| However, it could be argued that small continuous amounts
| of superstition and magical thinking (like regular
| horoscopes) weakens people over time, so that they are
| vulnerable to the larger stuff (like essential oils) or
| even larger and more harmful conspiracies later.
| odyssey7 wrote:
| On the other hand, astrology is decentralized and requires
| individuals to find their own values, and to actively
| interpret the meaning of things they read. I find that
| being this engaged with something enhances critical and
| creative thinking.
|
| And in the case of astrology, self-awareness.
| teddyh wrote:
| Encouraging people to "find their own values" and to
| "actively interpret the meaning of things they read" ,
| _without_ any grounding in reality or science, will
| mostly result in people either growing more ardent in
| their existing beliefs (whatever they happen to be), or
| make people spin wildly out of control in conspiracy
| theories and /or magical thinking and superstitions.
| throwamon wrote:
| Oh, so it's just like philosophy and science, except
| without any philosophical or scientific backing.
| pxc wrote:
| No. Astrology is a somewhat mystified, ritualized form of
| useful reflexive and social activities, namely thinking
| about personality and long-term thinking about life
| decisions.
|
| Just like how a funeral at a church is a somewhat
| mystified, ritualized form of the useful reflexive and
| social activities of remembering and grieving.
| bcrosby95 wrote:
| Add Santa and the tooth faerie to the list.
| whoisjuan wrote:
| > I may be open-minded
|
| You're not. If you were you will understand that astrology and
| other esoteric beliefs are culturally anchored to the human
| experience of many people in the world. In particular the self-
| development that many people seem to get from astrology. I
| don't need to believe in astrology to understand its cultural
| role.
|
| I think it's completely fair to build a business around a
| cultural idea and use that idea as a thematic glue to teach
| people about self-development and self-care. If you donwload
| the app, you will quicky realize that's exactly what they are
| doing. Personally not my thing, but I respect what they do and
| their approach to building a business around this.
| markn951 wrote:
| Well... they're not really "making" an astrology product.
| They're an engineer "making" an application backend. It's
| almost kind of irrelevant what it's being used for in this
| context (a relatively technical discussion on the merits of a
| language).
| teddyh wrote:
| Sure, they might be honest about this - who knows? But anyone
| known to be peddling snake oil _doesn't_ get the benefit of
| the doubt. If they're telling the truth, there will be
| others, more trustworthy, who can make the same argument.
| dang wrote:
| Please don't take HN threads on generic flamewar tangents.
| They're tedious, predictable, and usually turn nasty.
|
| https://news.ycombinator.com/newsguidelines.html
| whimsicalism wrote:
| I hardly think criticizing astrology is a generic tangent for
| an astrology company as per the rules.
| dang wrote:
| It definitely is. It's a cliche, threadbare topic about
| which people adamantly repeat platitudes they settled on
| long ago.
| teddyh wrote:
| If there were an article about Rust posted to HN from, say,
| the Church of Scientology, would criticism of CoS be
| disallowed? Some things should be called out when you see
| them.
| dang wrote:
| You need to understand what we're going for on this site:
| curious conversation. Curiosity withers under repetition
| and burns under indignation. Therefore, topics that combine
| a lot of repetition with a lot of indignation are not what
| we're looking for.
|
| They also have a habit of taking over an entire thread very
| quickly, much as fire consumes and spreads quickly through
| what it touches (which is why 'flame' is a good metaphor
| for the corresponding kind of internet comment).
|
| There are a lot of past explanations of these principles in
| case any of it is helpful:
|
| _repetition is bad for curiosity_ https://hn.algolia.com/?
| dateRange=all&page=0&prefix=false&so...
|
| _good discussion is specific, not generic_ https://hn.algo
| lia.com/?dateRange=all&page=0&prefix=true&sor...
|
| _reflective responses are better than reflexive ones_ http
| s://hn.algolia.com/?dateRange=all&page=0&prefix=true&sor...
|
| _trying to avoid the internet callout /shaming culture_ ht
| tps://hn.algolia.com/?sort=byDate&type=comment&dateRange=a.
| ..
|
| (and so on)
| Nav_Panel wrote:
| I know one of the founders, and she has a deep background in
| philosophy and psychoanalytic theory, as I do as well.
| Astrology as a contemplative and epistemological practice has
| deep roots; the idea that astrology is "real" in a physical
| causal sense goes back to Ptolemy and only persists because of
| the historical influence of the Christian church. I've written
| a bit on the topic here:
| https://listed.to/@simpolism/27322/what-is-astrology
|
| As an engineer who's also studied a bit of astrology and has
| played around with how one might produce a description language
| to support the astrological symbolic apparatus, I think a
| functional language is a great choice. The idea of strict types
| defined as a set of symbols makes perfect sense in astrological
| terms. Although I'm much more familiar with OCaml/SML than
| Haskell, a basic outline would be something like:
|
| type Planet = Sun | Moon | Mercury | ...
|
| type Sign = Aries | Taurus | ... | Pisces
|
| type House = 1 | 2 | ... | 12
|
| Using this, you could represent a whole chart in a pretty
| straightforward way. And then you could have higher order
| constructs, which represent meaningful formal relationships,
| like:
|
| type Aspect = (Planet, Planet, Degree)
|
| type Rulership = (Planet, Sign)
|
| etc. It's a pretty natural idea, to use a strong type system to
| represent what is effectively a formal language (astrology).
| whimsicalism wrote:
| > I know one of the founders, and she has a deep background
| in philosophy and psychoanalytic theory, as I do as well.
| Astrology as a contemplative and epistemological practice has
| deep roots; the idea that astrology is "real" in a physical
| causal sense goes back to Ptolemy and only persists because
| of the historical influence of the Christian church. I've
| written a bit on the topic here:
| https://listed.to/@simpolism/27322/what-is-astrology
|
| Sorry, how does this justify lying and deceiving people for
| profit?
|
| > she has a deep background in philosophy and psychoanalytic
| theory,
|
| By "deep background" you mean she got a BA in psychology?
| Nav_Panel wrote:
| > lying and deceiving people for profit?
|
| Who here exactly is being lied to? Some people feel that
| doctors lie to them, so they don't go to doctors.
| Similarly, if someone feels like astrology is all a big
| lie, they don't have to use the app.
|
| > By "deep background" you mean she got a BA in psychology?
|
| I mean she's done quite a lot of reading on enlightenment
| and modern philosophy, can hold a conversation on Kant,
| Hegel, etc. as well as Freud, Lacan, RD Laing, and others.
| Humanities degrees tell me very little about the quality of
| someone's understanding.
| cogman10 wrote:
| > Astrology as a contemplative and epistemological practice
| has deep roots
|
| I've never understood this as an argument for veracity. There
| are lots of ideas and practices with "deep roots". Blood
| letting has "deep roots", yet we've pretty thoroughly
| debunked humor balancing and good medicine.
|
| Astrology, like other psuedosciences, seems built on the
| notion that if you add enough lingo it becomes valid. Yet a
| quick skeptical consideration of "Ok, what does the position
| of a rock in the sky have to do with my day to day life"
| seems like it should readily debunk it. Why does the position
| of Jupiter, for example, have more effect on my life than say
| the position of the moon? Or 624 Hector? If I throw a rock
| over someone's head does that have an appreciable effect on
| their "luck" or how their day will go? Does the composition
| of said rock impact a person's luck?
| Nav_Panel wrote:
| > Why does the position of Jupiter, for example, have more
| effect on my life than say the position of the moon?
|
| It doesn't particularly matter. You can use a randomly
| generated chart and it will still "work", because the use
| of astronomy in astrology is basically as RNG, and
| astrology itself is a psychological language.
|
| > Blood letting has "deep roots", yet we've pretty
| thoroughly debunked humor balancing and good medicine.
|
| Do you really think modern medical psychology has moved
| past the "blood letting" phase of knowledge? If so, then
| why are so many people still depressed, anxious, etc,
| despite all the supposed advances?
|
| The fact is that psychology has a long way to go before it
| can be treated as a proper physical science, requiring
| researchers to bridge vast gaps in neuroscience and the
| structure of experience, which includes the huge and
| significant role of symbols in life.
|
| As it stands, the person with the most knowledge of your
| own life is... you, and tools like astrology function as
| _mirrors_ to help you avoid your own biases when developing
| self-knowledge. This is entirely unlike any medical
| intervention I 'm aware of, and cannot be compared in kind.
| cogman10 wrote:
| > Do you really think modern medical psychology has moved
| past the "blood letting" phase of knowledge? If so, then
| why are so many people still depressed, anxious, etc,
| despite all the supposed advances?
|
| A common misunderstanding of psychology is that it's
| about "curing" psychological illnesses. Almost all
| psychological illnesses are chronic and not diseases that
| can be cured. As such, the work of a psychologist is
| almost always around managing, not curing.
|
| You wouldn't, for example, look at the physical therapy
| an amputee receives and go "Physical therapy must be no
| better than blood letting because amputees still exist!"
|
| > The fact is that psychology has a long way to go before
| it can be treated as a proper physical science, requiring
| researchers to bridge vast gaps in neuroscience and the
| structure of experience, which includes the huge and
| significant role of symbols in life.
|
| That's happened perhaps more than I think you'd expect.
| This is where, for example, SSRIs have come from. It's
| not random shots in the dark and guesses. The unfortunate
| problem is there's a bunch of stigma around taking
| medicine for psychological problems.
| Nav_Panel wrote:
| > You wouldn't, for example, look at the physical therapy
| an amputee receives and go "Physical therapy must be no
| better than blood letting because amputees still exist!"
|
| And yet, we know the precise cause and details of their
| situation...
|
| > This is where, for example, SSRIs have come from. It's
| not random shots in the dark and guesses.
|
| SSRIs were designed with a specific neurotransmitter in
| mind, but the reason why serotonin can affect what we
| call "depression" is, as wikipedia puts it, "somewhat
| uncertain". Only in the last couple of years have
| theoretical frameworks appeared where we can kind of
| develop a causal understanding, like in Friston's REBUS
| paper:
| https://pharmrev.aspetjournals.org/content/71/3/316
|
| The gist is that, if serotonin modulates high level
| neurological priors, then SSRIs lead to slightly
| increased plasticity wrt the environment, which can help
| people get "unstuck" from previous environmental priors
| i.e. trauma. But if their current environment is poor,
| then SSRIs will have no effect or make them worse. If
| this model is correct, then it necessitates a shift in
| the etiology of depression, back to the more classical
| psychoanalytic "epistemic" view (in which "mental
| illness" is equivalent to unwanted patterns of thought
| and action, a definition that should feel obvious to
| anyone who's dealt with their own psychic distress) vs
| the modern "neurotransmitter" view (i.e. "not enough
| serotonin = depressed").
|
| The result is that any etiological understanding must
| include not only the present state of the individual
| seeking treatment, but also their environmental and
| historical contexts, i.e. their whole life. This
| problematizes the metaphor of mental illness, because, as
| you said, most people think you can treat mental illness
| like curing an infection, removing some sort of foreign
| element which resulted in whatever deviation from the
| "healthy" norm, without realizing it has to be a longer
| term intervention, because the foreign element is...
| still you.
|
| Like physical therapy, there's plenty of stretches you
| can do on your own, and you're also in a unique strong
| position to evaluate your own environmental and
| historical context, compared with a therapist who can
| only know what you tell them (or what they can read
| between the lines). This is why reflective practices
| exist, like many religious exercises which give you a new
| pattern to consider (like on Yom Kippur, you think about
| your last year in terms of repentance, forgiveness, etc),
| but also like astrology, which "automatically" produces
| frames for contemplative reflection. The result of proper
| reflection is in action, which shifts the agent away from
| their old repetitive patterns and can actually provide
| the mythical-seeming cure for their mental illnesses.
| This form of "treatment" has been rediscovered in many
| traditions over the years, from Buddhism to Stoicism. It
| seems to only be in modern western culture where we
| delegate to experts the responsibility for our own
| psyches...
| cbhl wrote:
| You may disagree, but I read this comment as a gendered
| microaggression and I hope you will reconsider your stance to
| be inclusive of this sort of content on HN going forward.
|
| I see astrology as an entertainment product. Some folks take it
| way too far, and it's fine if you'd prefer to abstain. But I
| think that it is the same as with other vices (porn, casinos,
| gatcha games, etc) who, otherwise, can have very interesting
| technical problems.
| teddyh wrote:
| You don't know my gender, and the article has no author name
| attached.
| IncRnd wrote:
| > Forgive me if I don't want to read anything written by
| someone making an astrology product. I may be open-minded
|
| No. You are closed-minded. The article explained three reasons
| why Haskell was chosen, not about converting you to believe in
| Astrology. FUNCTIONS IN THE MATHEMATICAL SENSE
| TYPE-DRIVEN PROGRAMMING HASKELL MAKES ILLEGAL STATES
| UNREPRESENTABLE
|
| This is the tl;dr from the page, where there is nothing about
| Astrology:
|
| "Haskell is optimized for developer efficiency. You can get a
| lot done, have a high degree of confidence that it runs
| reasonably without having to do too much thinking or ass-
| covering. We move fast & need things to be reliable. Rather
| than hand optimizing Doom 2 for ___, Haskell is the opposite.
| The computers serve us. Code is for humans to read, and only
| incidentally for computers to read. Code is how humans express
| themselves to each other and computers, and it's up to
| computers to run it in a reasonably good way."
| teddyh wrote:
| I have enough to read already. I choose not to spend my time
| reading texts by known con artists, whatever the texts may
| contain. If the truths expressed therein are valuable,
| someone else with more authority can repeat or re-discover
| them elsewhere.
| User23 wrote:
| > I choose not to spend my time reading texts by known con
| artists
|
| And yet you have the time to impugn other people's
| character here? I propose to you that your time might be
| better spent on your reading backlog.
| weatherlight wrote:
| How is this not flagged?
|
| > I don't want to read anything written by someone making an
| _insert religious /philosophical belief here_ product.
|
| I'm not sure _the what 's_ being built takes a way from the
| correctness of _the way_ something was built.
| whimsicalism wrote:
| Why should it be flagged? Seems like a perfectly reasonable
| comment, just like how in day to day life I think less of
| people when I learn that they are religious.
| weatherlight wrote:
| I'm an atheist, I say this because its against the hacker
| newsguidelines
|
| > Please don't use Hacker News for political or ideological
| battle. It tramples curiosity.
|
| https://news.ycombinator.com/newsguidelines.html
| pxc wrote:
| > I have limits where it comes to people who I know are trying
| to influence me into believing stupid false things to their
| benefit.
|
| The market for astrology already exists. Their whole thing is
| getting people who are into it to prefer them because their
| math is better.
|
| I get the anti-pseudoscience reflex, but (1) it's the wrong way
| to think about astrology and (2) it's weird to pick on
| astrology apps for their 'ethics' when the practice is more or
| less benign. We're not talking about a cult where people refuse
| medicine for their children here.
|
| From an employment perspective, Co-Star seems way cleaner than
| places where lots of people I know and like work. Better
| horoscopes than missile defense or spy drones or brutal
| retailers like Amazon. Better a stupid, fake typology than
| spyware that reads people's emails to hit them with more
| effective ads. Better to produce models of the positions of
| stars than models of human faces to power militarization of the
| Israeli border.
|
| Re: (1)
|
| Astrology as most people practice it is a low-stakes system of
| prompts for reflecting on oneself and one's environment in a
| way that is useful and healthy, but can easily be neglected
| when you're just trying to get from one day to the next. Taking
| it too seriously is a mistake, but it can be useful without
| being correct about the capacity of the power of heavenly
| bodies to determine human personalities or affairs.
|
| If we had nobles using court astrologers again, I'd say
| attacking astrology as harmful would be valuable. But when it's
| more about prompting for reflection or producing a shared
| vocabulary of personality, I think it ranges from helpful
| ritual to benign nonsense.
| halfmatthalfcat wrote:
| I see a lot of python and js/node as basis of comparison against
| Haskell which seems really odd.
|
| I would be comparing Haskell more to Scala/Elixir/etc if you're
| trying to make an argument for Haskell.
| romero-jk wrote:
| To Scala yes, to Elixir? wut?
| remexre wrote:
| If you don't have experience with both, "Elixir is FP" and
| "Haskell is FP" makes it sound like "Elixir and Haskell are
| comparable" ig?
| dudul wrote:
| Why? Anything can be compared to Haskell. It's ok to compare
| things that are very different.
| uncomputation wrote:
| Very interesting and well thought out write up on a high level.
| Shame on me for being surprised at the technical clarity of an
| astrology app I suppose. On a lower level, I'm interested in how
| they balance the purity of Haskell with the necessity of a server
| actually persisting state and dealing with IO.
| anchpop wrote:
| Doing IO stuff is very well-supported in Haskell. Printing to
| the terminal just looks like: main = putStrLn
| "Hello World"
| uncomputation wrote:
| Doesn't this "contaminate" the entire calling function
| though, as in you now have to specify it is impure?
| samhh wrote:
| Yes, impurity (or rather the representation thereof) is
| contagious. This is where the common "functional core,
| imperative shell" comes into play. You generally try to
| push side effects to the edge.
|
| There are other approaches you can take too, like encoding
| your effects in a monad which has a different runtime
| representation in tests. It's like mocking on steroids with
| type safety.
___________________________________________________________________
(page generated 2021-11-05 23:01 UTC) |