Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Oct 18 19:35
    @SethTisue banned @lunaterra22
  • Sep 14 18:08
    @SethTisue banned @discjock:matrix.org
  • Sep 12 20:37
    @SethTisue banned @manuelzamoratetherbtcusa:matrix.org
  • Sep 06 14:29
    @SethTisue banned @white_hat_hacker:minds.com
  • Sep 06 14:29
    @SethTisue banned @alexchole:matrix.org
  • Aug 31 17:03
    @SethTisue banned @andersonwatts7:matrix.org
  • Jul 19 20:37
    @SethTisue banned @tonyobanon
  • Jan 02 23:58
    @SethTisue banned @fakubishes:nerdsin.space
  • Dec 15 2021 05:01
    som-snytt commented #12516
  • Dec 15 2021 04:38
    SethTisue edited #1312
  • Dec 15 2021 04:38
    SethTisue opened #2273
  • Dec 15 2021 04:31
    jackkoenig opened #12516
  • Dec 15 2021 04:29
    SethTisue edited #1312
  • Dec 15 2021 04:28
    SethTisue edited #1312
  • Dec 15 2021 04:27
    SethTisue labeled #9831
  • Dec 15 2021 04:27
    scala-jenkins milestoned #9831
  • Dec 15 2021 04:27
    SethTisue labeled #9831
  • Dec 15 2021 04:27
    SethTisue opened #9831
  • Dec 15 2021 03:35
    som-snytt commented #11339
  • Dec 15 2021 03:27
    som-snytt labeled #12494
Jose C
@jmcardon
yeah but when did any of us here claim FP is the hammer for all nails?
might sound like it but remember this is a Scala room and most people here are writing scala applications
trepidacious
@trepidacious
@Richtype If the individual/small business is not writing a game what's the connection though?
Jose C
@jmcardon
for the same reaosn the majority of games (note: not minecraft though minecraft performance isn't great either)
are not on the jvm
trepidacious
@trepidacious
Jose C
@jmcardon
A good chunk of the FP folk here are speaking in the web/backend/distributed systems domain where scala is being used, because, welp, we're in a scala room
At no point it's been implied that our statements re: FP extend to games, RTOS or anything really performance sensitive
So really, I believe you're strawmanning quite hard here
Rich
@Rich2
Well I am writing a game(s) /game engine. So I am biased, but I also think games are a great way for people to learn to code, or rather could be a great way to learn to code.
Jose C
@jmcardon
Ok great, and that's awesome, but scala isn't a lang where game engine code is usually written
trepidacious
@trepidacious
I have wondered occasionally about an FP game representing often-changing state as a function with time, so that we only need to produce a new state when something changes for reasons other than just the passage of time
Jose C
@jmcardon
yeah but a lot of purity is achieved in FP by thunking, and this has overhead
and depending on the game ms delays do matter
trepidacious
@trepidacious
From using a completely immutable data structure in a UI that was happy at 60fps I feel like it's maybe practical, possibly with the usual occasional tolerable GC glitch
Jose C
@jmcardon
but you weren't rendering like, AAA-tier graphics
I'm guessing
or games where there's so many environment artifacts that GC would be awful to use
or just look at minecraft
Ghost
@ghost~55118a7f15522ed4b3ddbe95
you can have purity and mutable data structures
they are largely orthogonal
Seth Tisue
@SethTisue
@trepidacious re "FP game representing often-changing state as a function with time", you might enjoy this series: http://prog21.dadgum.com/23.html
Rich
@Rich2
Its great that we've got Twitter, the Guardian, Banks and all the other high powered cutting edge Scala users, but I want Scala to become more accessible to simple games, other simple creative software, personal information management, scientists and the like. At the moment Python seems to be cleaning up the field.
trepidacious
@trepidacious
@jmcardon I think you might end up with something using FP for game logic running on an engine that might use mutation internally
Fabio Labella
@SystemFw
btw, if the threshold is small games with no AAA graphics, you can write those in Haskell as well (people do)
trepidacious
@trepidacious
@jmcardon I would guess that might work well since the code outside the engine might well not require amazing efficiency, but benefit a lot from being easier/more reliable to write (maybe :) )
Jose C
@jmcardon
yeah actually IIRC there's some steam games written in haskell
@Richtype that's much harder to do. Loads of scientists don't care about writing nice software. They just care about writing something that marginally works
python excels because the barrier of entry is almost just knowing how to put your thoughts in pseudo and it's almost python
trepidacious
@trepidacious
@Richtype It would be great to have a language that has both a shallow learning curve and great long term scalability, but it doesn't seem to have happened yet.
Jose C
@jmcardon
It also excels in causing headaches down the line, but you'll be hard pressed to convince many scientists to switch to scala when a good chunk of them don't give a crap about the code itself, only what it idoes
trepidacious
@trepidacious
@Richtype Maybe because it's not actually possible, some of the things that you need for scalability seem to be things that are not completely straightforward
Jose C
@jmcardon
Case in point: I worked in Civil Engineering research many years ago writing Matlab, and no one questioned my then-awful code.
It was practically crap looking at now, from my POV, but it worked and it served as a proof of concept and it was part of a Ph.D defence
Eric Li
@EricLiCA
because scientists don't write software that has to be maintained for years, you program to explore data, gain insights, and then throw it out
Rich
@Rich2
val bread = 0.70
val butter = 0.62
val cheese = 1.22
println(bread + butter + cheese)
A useful potentially useful programme that I would suggest doesn't need an IO Monad.
Jose C
@jmcardon
exactly
@EricLiCA hence why I don't believe scala can ever beat python in that
Eric Li
@EricLiCA
yeah, use the right tool for the job
trepidacious
@trepidacious
@Richtype Yeah but it's also not really much more complicated with an IO monad if that's how you've chosen to print things?
Jose C
@jmcardon
you're on the money with that. It's cool to want to make scala more accessible, I just don't think that it's a winnable battle to convert all the scientists to use it.
trepidacious
@trepidacious
@Richtype I mean only the last line changes?
Fabio Labella
@SystemFw
do 
 let bread = 0.70
 let butter = 0.62
 let cheese = 1.22
 putStrLn (show bread ++ show butter ++ show cheese)
the equivalent with an IO monad. I'd argue a PhD is not needed
Eric K Richardson
@ekrich
But machine learning and other data pipelines blur the lines. Is Python ok or is Scala better?
trepidacious
@trepidacious
I'm tempted to say python is never ok, but that would feel unconstructive
Monaddle
@monaddle

Been doing a task recently that I find myself really wishing I used python for. I've lately been writing software to migrate files from servers up to Azure. I picked Scala because I pick Scala for everything. The task involves making some system calls (converting .rar archives to .zip), and a number of other string massaging type tasks.

Scala is really great for writing complex software because you get a really fast, trustworthy feedback loop on correct vs. not correct, but for this particular task, the feedback loop is terrible. It's easy to get it compile, but to test in-situ I've got to bundle it up and ship it out to the server, so the feedback loop is just terribly slow. I can't install dev tools in-situ, but could modify python scripts with a text editor.

In retrospect, Python would have probably quartered the dev time.

trepidacious
@trepidacious
@DanielPorter That's not the language though, that's the tooling?
Jose C
@jmcardon
if it's just some scripting I don't bother with scala either
Rich
@Rich2
I've always vehemently disagreed with Any2StringAdd, but I'm very much in sympathy with the intent behind it- to create a concise beginner accessible language.
Fabio Labella
@SystemFw
the problem is that I'm afraid that doesn't scale