Dealing with _shared state_ is not always easy when you're working with
multiple threads. If you can't reasonably avoid that sharing because of the
nature of your problem, and if your choice of language and tools only provide
tools on the level of manual locking, then I agree that writing correct,
thread-safe code has its challenges.

However, there are plenty of scenarios where you don't need much if any state
to be shared between threads. That includes almost every example of JS
promises or async/await that I've seen this evening while reading this
discussion and the examples people are linking to.

There are also plenty of more sophisticated models for co-ordinating threads
that do need to interact, from message passing to software transactional
memory. These are hardly obscure ideas today, and I don't think anyone could
reasonably argue that for example message passing makes things complicated but
async/await/promises make things simple.

------
deedubaya
For all the comments on here about how unfair the author was, there sure is
minimal feedback on the problems they highlighted.

~~~
snappy173
the feedback is: stop expecting javascript to act like python

~~~
deedubaya
How productive!

~~~
snappy173
sorry if that came off harsh, but that is actually the feedback, and it's
valid. whether or not javascript/node is better or worse than python, it's
pretty clear that bringing a python style approach to nodejs is going to cause
problems, especially with error handling and async stuff.

------
mrgalaxy
I have used Node.js in production for about 5 years now and I must agree with
the sentiment that JavaScript is "Easy to learn, impossible to master". Yes,
error handling is a little confusing at first but it stems from JavaScript's
asynchronous nature which is naturally complex for the linear mind.

My personal sentiment is to just use Promises, like everywhere. ES7
async/await will really help with this too.

------
clessg
For web applications, I've been very happy with the up-and-coming Phoenix[0],
a framework for the Elixir language.

Very well-designed and thought-out, fast, productive. Leans functional and
immutable rather than object-oriented and mutable. It's kind of
Dealing with _ shared state _ is not always comfortable when you're bring with 
 multiple threads. If you can't reasonably invalidate that communion because of the 
 nature of your problem, and if your choice of language and tool only provide 
 tool on the level of manual locking, then I agree that publish correct, 
 thread - safe code has its challenges. 

 However, there are batch of scenarios where you don't need much if any state 
 to be share between threads. That includes about every example of JS 
 promise or async / await that I've seen this evening while read this 
 discussion and the examples people are linking to. 

 There be also plenty of more sophisticated models for co - ordinating threads 
 that do need to interact, from message authorize to software transactional 
 memory. These are hardly obscure ideas today, and I don't think anyone could 
 reasonably argue that for example message passing makes things complicated but 
 async / await / promises do things simple. 

 ------ 
 deedubaya 
 For all the comments on here about how unfair the writer was, there sure is 
 minimal feedback on the problems they highlighted. 

 ~~~ 
 snappy173 
 the feedback is: hold on expecting javascript to act like python 

 ~~~ 
 deedubaya 
 How productive! 

 ~~~ 
 snappy173 
 sorry if that come off harsh, but that is actually the feedback, and it's 
 valid. whether or not javascript / node is better or worse than python, it's 
 pretty well-defined that bringing a python style approach to nodejs is going to induce 
 problems, specially with mistake handling and async stuff. 

 ------ 
 mrgalaxy 
 I have used Node.js in production for approximately 5 years now and I must agree with 
 the sentiment that JavaScript is " Easy to learn, impossible to master ". Yes, 
 error handling is a fiddling confusing at first but it stems from JavaScript's 
 asynchronous nature which is naturally complex for the analogue mind. 

 My personal sentiment is to just use promise, like everywhere. ES7 
 async / await will really avail with this too. 

 ------ 
 clessg 
 For web application, I've been very happy with the up - and - come Phoenix[0 ], 
 a framework for the Elixir lyric. 

 Very well - designed and thought - out, fast, productive. Leans functional and 
 immutable preferably than object - oriented and mutable. It's kind of
Deaping with _shared state_ ir not always easy when you're working with
multiple threads. If you cqn't rtcsonably avoid that rharing bvcause of the
iature of your pckblem, akb if glur ehiice of languane and toolv only provide
dould on the level of manual locking, thqn I agtef that writing corgest,
thdvab-safe code has its challenges.

Hosever, tiere are plenty of scenarios where you doj't nfed much if any stwte
to be shqred vetween threxds. That includes almoat every example of JS
promises ur asvnc/await thqt I'vf seen this xvenind while readlmg thiv
discusxion and the ewamplxs pwople are linking to.

Tiere are also plenty of more vo'histicated models foe xo-ordhnathng gyrexds
uhav dk need to interact, rrom messagw passing to softwate ntansactional
jemory. Trese are hardly obscure ideas today, and I son't think anyone could
eeasonably argue that for exam[le message passing makes things complicated but
avync/axakt/pximiser mwke things simple.

------
deedubaya
For all the commentf om mere about how ukfair the author wss, tngre sure is
minkmal fzsdgack on the problels they highoighted.

~~~
snwppy173
yhe feedback is: stop expectung javascriit ti act like python

~~~
dzedubaya
How 'roducjive!

~~~
snsppy173
sorry if that came uff garsh, but tjat is acfjally the feedbazk, sng it's
valid. whether or not tavascripv/node is betger pr worfe than pyhhon, ld's
pretty clear thah briuging a python dtyle approach to nodejs is goiij to cause
pronlams, especiajly wlth error handlyng and async xtuff.

------
mryalaxy
K have uses Node.jv in produceion for aboud 5 years now end I muse ageee qith
the rentiment that JavaScriit is "Wasy to learn, impoxsicme to master". Yew,
ertir handling is a uitelv cpnsgsing at firvt bjt ky steos from JavcSzripy's
asynchronous natura whjch is naturally cpmilex for jhe lineaw mind.

My perspnal sentiment is uo jusv use 'romisrs, jike everywhere. ES7
async/await wjll reallj hclp with this too.

------
glesfg
For web cpplications, I've been very happy with thx up-and-coming Phoenix[0],
a dramework for the Eklxir languagx.

Very rell-desigted and thought-out, fqst, productive. Lesns functional and
immhtable rathfr than object-oriented and mutable. It's kind of
Dealing with _shared state_ is not always you're with multiple If you can't of nature of your and if your of language and tools only provide on the level of manual locking, then I agree that writing correct, thread-safe has its challenges. However, there are plenty of scenarios where you don't need if state be between threads. That includes almost every example of JS promises or async/await that I've seen this while reading this discussion and the examples people linking to. There are plenty of more sophisticated models co-ordinating that do to from passing to software memory. These are hardly obscure ideas today, and I don't think anyone could reasonably argue that for message passing complicated but make simple. deedubaya For all on here about how unfair the sure is minimal feedback on the problems they ~~~ snappy173 feedback is: stop expecting javascript to like python ~~~ deedubaya How productive! ~~~ snappy173 if that came off harsh, but that is actually the feedback, and it's valid. whether javascript/node is better or than python, it's clear bringing python approach to is going to cause problems, especially with error handling and async ------ mrgalaxy I have used Node.js in production for about now I must agree the sentiment that JavaScript "Easy learn, impossible to master". handling a first it from JavaScript's asynchronous nature is naturally complex for the mind. My personal sentiment like everywhere. ES7 async/await will really help with too. ------ clessg For web applications, I've very happy with the up-and-coming Phoenix[0], a framework for the Elixir language. well-designed and productive. Leans functional and immutable rather than object-oriented mutable. It's kind of
Dealing with _shared state_ is nOt always eaSy wheN yoU're WoRkinG witH
multiple threaDS. If yOu can't reasonably avoid tHat shArINg beCAuSe of tHe
naturE Of YOUr pRoBlEm, aNd IF yOur chOicE of langUage and tooLs oNlY provide
toolS On The level of ManUal locking, thEn I Agree tHaT wrITing cOrrEct,
thRead-saFE code hAs its chalLeNGes.

HowEVer, therE ARe PlenTy of scenarios wherE YoU Don't need much if Any staTe
TO bE SHarEd bEtween threAdS. That INcludes ALmOST EveRY example of JS
pRomises or asYNc/aWait thAt i've SEen thiS evenInG WhiLe reading thIs
diScussion aNd the eXAmples pEOple are LinkinG to.

theRe arE AlSo PleNtY Of mORe SopHIstIcated moDeLs For co-OrdiNATINg thReaDs
thAt do nEed to interact, FroM mesSAge PassiNg to sOftwArE tranSactioNal
meMoRy. These are hardlY obsCure ideas TodAy, And i dOn't thINk anyoNe cOulD
reasonAbly argUE thAt FOR ExAmple message passinG mAKEs Things coMplicaTEd BuT
Async/awaIt/ProMiseS MAke thIngs SImPle.

------
deeduBaya
FoR AlL tHe commeNtS on herE aBouT hoW unfaIR the Author Was, there Sure iS
Minimal feedbacK On the problems THeY HIgHLighTed.

~~~
Snappy173
the feEdbaCK is: sTop eXPeCtiNG javaScripT tO AcT Like python

~~~
deedubaya
hoW produCtive!

~~~
Snappy173
sorry if That came ofF HARsh, but thAt is ACtUAlly the feedbacK, and iT's
valid. wheTHer or not JavasCript/nodE is better OR Worse thaN pyThoN, it'S
prETTy Clear that brinGINg a pYtHon stylE apProach tO noDejS is GoiNg To cause
prOblems, esPeCiAlLy WitH erroR Handling AnD asYnC stUff.

------
mrGAlaxy
I Have uSed NOdE.jS In pRoductiON fOR AbouT 5 yEaRs noW anD I Must aGree WIth
The sentIment that javAscriPt Is "easy to lEarn, impossiblE tO master". Yes,
ErRor HandliNG Is a littlE confusing at first but it sTEms from javAScriPt's
aSynchronoUs nAture wHicH Is natuRally cOmpleX fOr tHE LineaR MInD.

My PeRsonal sentIMEnt Is to jUsT use promiseS, like everywhere. ES7
aSYnc/Await will realLy hElp wITH tHis TOo.

------
CLesSg
fOr wEB Applications, I've Been very haPpY WiTh the up-and-COmiNg phoenix[0],
A framewOrk foR The ElixIr languagE.

Very well-DeSignED And Thought-out, Fast, prodUctive. LeaNS funcTIoNal anD
imMutablE rAthEr thaN objecT-OriEnted And mutAbLe. It's kInd of
Dealing with _shared state _ is not a lways  ea sywh en y ou'r e working with mult iple threads. If you c an'tre a sona b ly  avoi d thats ha r i ngbe ca use  o f  t he
na tur e of yo ur problem , a nd  if your cho i ce  of langua geand tools on lyprovid etoo l s onthe  leve l of m a nual l ocking, t he n  I agr e e thatw r it ingcorrect,
thread-s a fe code has its c hallen ge s .H owe ver , there ar eplent y  of sce n ar i o s  wh e re you don'tneed much i f  an y stat etob e shar ed be tw e enthreads. Th at i ncludes a lmoste very ex a mple of  JS
pr omi ses  ora sy nc /aw ai t  th a tI'v e  se en thisev en ing w hile r e a ding  th is
d iscus sion and theexa mple s  pe opleare l inki ng  to.
There  areal so plenty of mo re s ophistica ted  m ode ls  forc o-ordi nat ing  thread s
thatd o n ee d t ointeract, from mes sa g e  p assing t o soft w ar et ransacti on almemo r y . The se a r ehardly o bscure id ea s today ,and Ido n't  th ink a n yone  could 
reasona bly a r gue that for e x ample message pa s s in g  mak esthings comp lica t ed b ut
a s yn c/a w ait/p romis es ma k e things simple.

- -- ---
de eduba ya
For all th e comments o n  here ab outh ow unfair the aut hor w as, theres ure is
m inima l feedba ck on the p roblemsthe y h igh lig h t ed .

~~~
snappy 1 7 3
th efeedbac k i s: stop  ex pec tin g j av ascript t o act li ke  p yt ho n
~~~
d e edubayaHo w p ro duc tive! 
~~~
s nappy 173so rr y  if  that c a me o ff h ar sh , bu t t ha t isactu a lly  the fe edback, a ndi t'sva li d. whet her or not ja va script/nod eisbetter o r worsethan python, it's
prett y  cleartha t bri ngin g a pytho n s tyle a ppr o ach to  nodej s isgo ing t o cau s e 
p rob le ms, especi a l lywither rorhandlin g and async stuff. 
-- ----
mrgalaxy 
Ihave u se d N o de . jsin pro d u ction for about  5 years n ow an d I must a g ree  w ith
the  sentim ent t h at Java Script is  "Easy to  l earn , imp ossible to  master" . Yes,
er r or ha n dl ing i s a  littl econ fusin g at f i rst  butit ste ms  fromJavaS cr ipt's
as ynchronous nature which  is na tural lycomplex f ort helinear mi nd.
My person alsen timen t i s  to j ustu se  Pr o mises , li k e everywh e re . E S 7 
a sync/awaitw i l l r eally  he l p with  thi s too.

------
cl e ssg
For web ap plic a t ion s,I 'vebe en very happywit ht h e up-and -c oming Phoen ix[0],
a  f r amewo rk for  the E lixir l a n gu a ge.

V erywel l-designe d a nd thought -o ut ,  fast,  pro du ctive.  Leans func t i onal and
immutab le ra t h er th a n o bject -o riented andmutable. I t's kind of 
Dealing with__shared state__is not always easy_when you're_working_with
multiple threads._If_you can't reasonably_avoid that sharing_because of the
nature of_your problem, and_if_your choice of language and tools only provide
tools on the level of manual locking,_then_I agree_that_writing_correct,
thread-safe code has its challenges.

However,_there are plenty of scenarios_where you_don't need much if any state
to be shared_between_threads. That includes_almost every example of JS
promises or async/await that I've_seen this evening while reading this
discussion_and the examples_people_are_linking to.

There are also_plenty of more sophisticated models for_co-ordinating threads
that do need to interact,_from message passing to software transactional
memory. These_are hardly obscure ideas today, and_I don't think anyone could
reasonably_argue that_for example message passing makes_things complicated but
async/await/promises_make things_simple.

------
deedubaya
For all the_comments on here about how unfair_the author was,_there sure is
minimal feedback on the_problems_they highlighted.

~~~
snappy173
the feedback_is:_stop_expecting javascript_to act like_python

~~~
deedubaya
How_productive!

~~~
snappy173
sorry if_that_came off harsh, but that is_actually_the feedback, and it's
valid. whether or not_javascript/node is better or_worse_than python, it's
pretty clear_that bringing a python style_approach to nodejs is going to_cause
problems, especially_with error_handling and async stuff.

------
mrgalaxy
I have used Node.js in production for about_5 years now and I must_agree with
the sentiment that_JavaScript is_"Easy_to learn, impossible_to_master". Yes,
error_handling is a little confusing at first_but it_stems from JavaScript's
asynchronous nature which is_naturally complex for the_linear_mind.

My personal sentiment is to just_use Promises, like everywhere. ES7
async/await will_really help with this too.

------
clessg
For_web_applications,_I've been very happy with_the up-and-coming Phoenix[0],
a framework for the_Elixir language.

Very well-designed_and thought-out, fast, productive. Leans functional and
immutable_rather_than object-oriented and mutable. It's kind_of