TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Goless: Go-like semantics built on top of Stackless Python

50 pointsby im_darioalmost 11 years ago

5 comments

sarnowskialmost 11 years ago
IIRC stackless python implemented microthreads and channels before go existed - thats the whole point of stackless python - so whats the benefit here on top of that?<p><a href="http://www.stackless.com/wiki/Tasklets" rel="nofollow">http:&#x2F;&#x2F;www.stackless.com&#x2F;wiki&#x2F;Tasklets</a> <a href="http://www.stackless.com/wiki/Channels" rel="nofollow">http:&#x2F;&#x2F;www.stackless.com&#x2F;wiki&#x2F;Channels</a>
评论 #8184288 未加载
评论 #8184945 未加载
评论 #8184208 未加载
评论 #8184040 未加载
评论 #8184240 未加载
评论 #8183966 未加载
jmoironalmost 11 years ago
What tulip should have been.<p>Being a long time gevent user, I found goroutines pretty familiar and even unspectacular (no pool.map?!). What really converted me to Go was all of the other ways I found writing Go programs to be more pleasant and less error prone than Python programs:<p>* consistent formatting for all code<p>* superior distribution story<p>* compiler magnitudes faster and more effective than pylint<p>* programs run faster and use far less memory<p>* far simpler semantics make it easy to read<p>* higher quality standard components (net&#x2F;http, eg)<p>What I traded for this was a 10-20% drop in productivity, which I was fine with. I use Python for all sorts of quick &amp; dirty tasks still, including some batch processing where there&#x27;s a big discovery phase, but I write all my software in Go.
ceptorialalmost 11 years ago
The big question is whether this mimics the &quot;non-blocking&quot; behavior of goroutines - if you block in a goroutine with a select on a channel in Go (or rather, if you do ANY synchronous operation, including network calls, channel operations, etc.), Go will automatically context switch off the goroutine and run another one. But if you have a tasklet that selects on a channel, will Goless&#x2F;Stackless automatically run a different tasklet, or will that tasklet stall a thread (or worse, the GIL)? What if the tasklet is doing a synchronous HTTP call or waiting on a future to complete?
评论 #8184918 未加载
pritambaralalmost 11 years ago
I&#x27;m pleasantly surprised to see pypy beat go by an order of magnitude in the select_default benchmarks. Could it be a bug, or is it real?
评论 #8184966 未加载
评论 #8184931 未加载
kristjanvaluralmost 11 years ago
Hi, I didn&#x27;t realise this was where all the cool kids hang out. Google alerts 4tw