Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在寻找一种非常简单的方法来在 Python中实现纤维。我确信有一个非常简单的方法可以使用生成器来完成它,但我的脑子里正在胡思乱想。这不适用于大型应用程序,所以我不需要像 Diesel、Tornado 或 Twisted 这样的花哨(或开销),我只想要一种巧妙的小方法来制作纤维。有什么想法/建议吗?
谷歌搜索 Python 协程。那里有很多复杂程度不同的东西。
我发现Greenlets几乎完全符合我的要求。甜的!