我已经关注扭曲有一段时间了。它看起来很有趣——这似乎是在编写服务器时利用大量功能的好方法。不幸的是,尽管使用twisted.web 编写了一些Web 服务器(通过阅读其他人的源代码和一本非常过时的O'Reilly 书),但我从未真正感觉到我已经对twisted 产生了亲和力……一定程度的理解这实际上给了我一些它看起来具有的力量。
我认为我需要一些好的文档来达到更好的理解水平 - 我根本没有时间仔细研究源代码,并且 SO 上的其他线程提到了 twisted 的官方文档,往好里说是不完整的,往坏了说是不存在,有时甚至非常过时。
有没有其他更彻底、更宽容、更有用的东西,或者我是否坚持使用另一个经典的、无聊的 STFU 和 RTFM,尽管 TFM 没有帮助?
更新
针对 JP Calderone 的评论,即我只是有一个婊子,在某种程度上我想我是,但考虑到 Twisted 的广度和价值以及缺乏明显、详尽的文档。我心里有一些想要调查的事情,但我一直得到不错的结果,只是将事情拼凑在一起并询问具体细节,而在我看来,我所寻求的更深入、更广泛的理解是没有帮助的。
立即浮现在脑海中的对比是 Django...我可以阅读(非常详尽的)Django 文档,但不一定知道如何立即执行它可以执行的所有操作,但我可以很好地了解如何< /em> 我可能会做我需要做的一切,并且确切地知道在时机到来时该去哪里寻找。
I've been looking at twisted for a while now. It looks interesting - it seems like a good way to leverage a lot of power when writing servers. Unfortunately, in spite of writing a few web servers using twisted.web (from reading other people's source and an extremely dated O'Reilly book) I've never really felt like I had reached an affinity with twisted... a level of understanding that actually gave me some of the power it seems like it has.
I think I need some good documentation to arrive at a better level of understanding - I simply don't have time to pore over the source, and other threads on SO have mentioned twisted's official documentation, which is patchy at best, absent at worst, and occasionally very out of date.
Is there anything else out there that is more thorough, more forgiving, and more useful, or am I stuck with another classic, boring STFU and RTFM even though TFM is not helpful?
Update
In response to JP Calderone's comment that I'm just having a bitch, to some extent I guess I am, but I think the breadth of the question is valid considering the breadth and value of Twisted and the lack of obvious, thorough documentation. I have a few things in mind that I wanted to investigate, but I've been getting OK results just hacking things together and asking for specifics when a deeper, broader understanding is what I'm looking for is, in my mind, not helpful.
The contrast that immediately springs to mind is Django... I can read over the (very thorough) Django documentation and not necessarily know how to do everything it can do immediately, but I can get a really good overview of how I might do everything I needed to do, and know exactly where to look when the time comes.
发布评论
评论(5)
我将重复这里的一些回答者所说的内容(他们都是很好的答案),希望提供一个比较全面的答案。
另请注意,所有新功能都附带新的 API(即参考)文档;我们希望这将使具有技术写作能力的人更合理地编写文档,而无需费力去理解方法名称的含义。
I'm going to repeat what some of the answerers here have said (they're all good answers) in the hopes of providing an answer that is somewhat comprehensive.
Please also note that all new functionality comes with new API (i.e. reference) documentation; we hope that this will make it more reasonable for people with technical writing skills to write documentation without having to struggle through even understanding what the method names mean.
扭曲介绍,作者:Dave Peticolas 对 Twisted 进行了令人惊叹的从头开始的概述。它从简单开始,然后开始变得越来越深入,同时解释沿途的一切。
我已经使用 Twisted 多年,发现这个介绍可以填补我所遗漏的所有空白,并阐明整个事情。绝对值得您花时间去看看!
The Twisted Intro by Dave Peticolas is an amazing overview of Twisted from the ground up. It starts simple and then starts getting deeper and deeper while explaining everything along the way.
I've been using Twisted for years and found this intro to fill in all those gaps I was missing and shed light on the whole thing. Definitely worth your time to check it out!
查看 Jean-Paul Calderone 的 60 秒内的 Twisted Web!
但是,老实说,Twisted 的官方文档并不完美,但我不会说它令人厌恶。里面有很多有价值的信息。
Check Twisted Web in 60 seconds by Jean-Paul Calderone!
But, honestly, the Twisted's official documentation is not perfect but I'll not call it disgusting. There's a lot of valuable info in it.
看看之前的文章...
Python 扭曲:从哪里开始
Take a look at this previous post...
Python twisted: where to start
O'Reilly 的书 Twisted Network Programming Essentials。
我还没读过,但目录看起来不错。
There's the O'Reilly book Twisted Network Programming Essentials.
I have not read it, but the ToC looks nice enough.